This topical collection summarizes recent advances in observing and modeling irradiance variations of the Sun and Sun-like stars, emphasizing the links between surface magnetic fields and the resulting solar and stellar variability. In particular, the articles composing this collection summarize recent progress in i) solar-irradiance measurements; ii) modeling of solar- and stellar-irradiance variability; and iii) understanding of the effects of such variability on Earths climate and exoplanet environments. This topical-collection overview article gives background and more details on these aspects of variability.