Spectral lines are emitted or absorbed when electrons change orbits, within the Bohr model of the atom.

The most abundant element in the Sun and other stars is hydrogen, and the second-most abundant element is helium.

The dominant spectral lines in starlight depend on the effective temperature of the stellar disk.

Radial motion produces a shift in the wavelength of a spectral line known as the Doppler shift. Outward motion along the line of sight produces a
redshift to longer wavelengths.

A gravitational redshift of radiation is produced when the radiation escapes the gravitational attraction of a star.

Spectral lines can be broadened by the thermal motions of the particles that produce the lines or by the rotation of the radiation source.

The wavelength of a spectral line can be split into three components in the presence of a magnetic field. Known as the Zeeman effect, the size of the
splitting can be used to measure the strength of the magnetic field and the polarization of the split lines can be used to determine the direction of the
magnetic fields.