Work out day length instantly with clear inputs, formula shown and shareable results.
Day length follows from the sunrise hour angle, whose cosine is -tan(latitude) tan(declination). At 51.5 degrees north on the June solstice, declination is about 23.4 degrees and the hour angle 122 degrees, giving 16 hours 22 minutes of daylight. The formula ignores refraction and the Sun's disc, which add roughly six minutes.
Sunrise hour angle
cos(H) = -tan(latitude) x tan(declination)
Day length
hours = 2H / 15
Because official times allow for atmospheric refraction and use the upper limb of the Sun, adding about three minutes at each end.
The cosine exceeds one in magnitude, meaning permanent day or night. The calculator limits latitude to 66 degrees for that reason.