Sunrise & Sunset Calculator

Calculate both sunrise and sunset times, day length, and twilight periods for any location and date using astronomical formulas.

DAY LENGTH
--
Sunrise
--
Sunset
--
Solar Noon
--
Declination
--

Understanding Sunrise & Sunset

Sunrise occurs when the upper edge of the sun's disk appears above the eastern horizon. Sunset is when the upper edge disappears below the western horizon. The time between these events is the day length, which varies throughout the year due to Earth's axial tilt of 23.45 degrees.

The difference between the longest and shortest days depends on latitude. At the equator, the variation is minimal (about 12 hours year-round). At 40 degrees latitude, day length ranges from about 9 hours in winter to 15 hours in summer. Beyond the Arctic and Antarctic circles, there are periods of continuous daylight or darkness.

The Sunrise Equation

cos(ω0) = −tan(φ) × tan(δ)
Sunrise = 12:00 − ω0/15 − lon/15 + UTC offset
Sunset = 12:00 + ω0/15 − lon/15 + UTC offset

Day Length by Latitude (Summer Solstice)

LatitudeDay LengthSunrise/Sunset Range
0° (Equator)12h 7mMinimal variation
30°N13h 56mModerate variation
45°N15h 37mLarge variation
60°N18h 30mExtreme variation
66.5°N (Arctic)24h 0mMidnight sun

Twilight Periods

  • Civil twilight: Sun is 0-6 degrees below horizon. Enough light for outdoor activities without artificial lighting.
  • Nautical twilight: Sun is 6-12 degrees below. Horizon is visible at sea; stars become visible.
  • Astronomical twilight: Sun is 12-18 degrees below. Sky not fully dark; faint stars may be obscured.

Frequently Asked Questions

Why is day length not exactly 12 hours at the equinox?

Atmospheric refraction bends sunlight, making the sun appear about 0.83 degrees higher than its actual position. Additionally, sunrise and sunset are defined by when the sun's upper edge (not center) crosses the horizon. These effects add about 6-8 minutes of extra daylight at the equinox.

What is the equation of time?

The equation of time corrects for Earth's elliptical orbit and axial tilt, causing solar noon to differ from clock noon by up to 16 minutes. This calculator uses a simplified model; for highest accuracy, the equation of time should be included.