Sunrise & Sunset Calculator
Find sunrise and sunset times for any location and date.
How It Works
Sunrise and sunset times are calculated using the NOAA solar position algorithm. The sun's position depends on the Julian Day (a continuous count of days since noon on January 1, 4713 BC), the observer's latitude and longitude, and the equation of time — a correction for Earth's elliptical orbit and axial tilt that shifts solar noon up to 16 minutes ahead or behind clock noon.
Solar declination is the sun's latitude on the celestial sphere. At the March and September equinoxes, declination is 0° and day length is approximately 12 hours everywhere. At the June solstice (declination +23.5°), northern latitudes have their longest day; at the December solstice (−23.5°), their shortest.
Hour angle is the key to finding sunrise and sunset. The formula cos(ω) = −tan(lat) × tan(dec) gives the hour angle at which
the sun's center crosses the horizon. The actual sunrise uses a zenith of 90.833° to account
for atmospheric refraction (~0.567°) and the sun's apparent radius (~0.267°).
Twilight types: Civil twilight (sun 6° below horizon) — enough light for outdoor activities without artificial lighting. Nautical twilight (12°) — horizon is still visible at sea. Astronomical twilight (18°) — sky is dark enough for most telescope work.
Polar phenomena: At high latitudes, if |tan(lat) × tan(dec)| > 1,
the hour angle formula has no solution. When cos(ω) < −1, the
sun never sets (midnight sun); when cos(ω) > 1, the sun never
rises (polar night).
Related Tools
Frequently Asked Questions
What causes sunrise and sunset times to change throughout the year?
Earth's axial tilt (23.5°). As Earth orbits the Sun, the tilt causes the Sun to appear at different angles in the sky. Near the summer solstice in the Northern Hemisphere, the Sun rises earlier and sets later; near the winter solstice, it does the opposite.
Why are there more daylight hours in summer?
Because of Earth's axial tilt. At the summer solstice (around June 21 in the Northern Hemisphere), the North Pole tilts toward the Sun, giving northern latitudes long days and short nights. The effect is more pronounced at higher latitudes — in Alaska, the sun barely sets in June.
What is the difference between civil, nautical, and astronomical twilight?
Civil twilight: sun is 0–6° below the horizon — enough natural light for most outdoor activities. Nautical twilight: 6–12° below — horizon still visible at sea. Astronomical twilight: 12–18° below — sky is dark enough for most telescope observations. Below 18° is true astronomical night.
What is solar noon?
Solar noon is when the Sun reaches its highest point in the sky for that day — directly south (in the Northern Hemisphere) or north (in the Southern Hemisphere). It is not necessarily 12:00 PM clock time; it can differ by up to 16 minutes due to the equation of time (Earth's elliptical orbit and axial tilt).
What are midnight sun and polar night?
Above the Arctic Circle (66.5°N), the Sun does not set for at least one day around the summer solstice (midnight sun), and does not rise for at least one day around the winter solstice (polar night). The extreme case is the poles themselves, where each lasts roughly 6 months.