Sign in to save

Bookmark this page so you can find it later.

Sign in to save

Bookmark this page so you can find it later.

Sunrise, Sunset and Day Length Calculator

Pick any location and date to see exact sunrise and sunset times, solar noon, day length, night length, and civil, nautical, and astronomical twilight times. Polar day and polar night are handled automatically.

Location

Requires browser permission. Or enter coordinates below.

Quick presets

Date and Time Zone

e.g. -5 for EST, +1 for CET, +5.5 for IST

Select a location to calculate sun times

Use the location panel to pick a city, enter coordinates, or allow browser geolocation.

Reference Guide

Why Day Length Changes

Earth's axis tilts at 23.5 degrees relative to its orbit around the sun. As Earth travels around the sun over the year, that tilt means one hemisphere leans toward the sun (summer, longer days) while the other leans away (winter, shorter days).

At the equator the effect is small: day length stays near 12 hours all year. At higher latitudes the effect grows dramatically. London ranges from about 8 hours in December to nearly 17 hours in June.

The two equinoxes (around March 20 and September 22) are the only days when every location on Earth has roughly equal day and night.

The Sunrise Equation

The standard sunrise equation uses an hour-angle formula. The sun rises when its zenith distance equals about 90.833 degrees (the extra 0.833 degrees accounts for atmospheric refraction and the sun's apparent disk radius).

The key formula is: cos(H) = (cos(z) - sin(lat) sin(dec)) / (cos(lat) cos(dec)), where H is the hour angle at sunrise, z is the zenith distance, lat is latitude, and dec is the sun's declination.

Solar noon occurs when the sun crosses the observer's meridian, roughly at 720 - 4 * longitude - equation_of_time minutes after UTC midnight.

Civil, Nautical, and Astronomical Twilight

Twilight is the period before sunrise and after sunset when the sky is still partially lit by sunlight scattered by the upper atmosphere.

  • Civil twilight (sun 0-6 degrees below horizon): bright enough for outdoor activities without artificial light. Legal definition for streetlights in many countries.
  • Nautical twilight (6-12 degrees below): horizon still visible at sea; navigators can take star sights.
  • Astronomical twilight (12-18 degrees below): sky dark enough for most observations; faint objects become visible.

Solar Declination

The sun's declination is its angle north or south of the celestial equator. It ranges from +23.5 degrees (June solstice) to -23.5 degrees (December solstice), crossing zero at the equinoxes.

Declination determines the sun's maximum altitude at solar noon: altitude = 90 - |latitude - declination|. A higher declination (summer in the northern hemisphere) means the sun climbs higher in the sky and shines longer.

The equation of time is a small correction (up to about 16 minutes) caused by Earth's elliptical orbit and its axial tilt, shifting solar noon slightly earlier or later than clock noon.

Polar Day and Polar Night

Above the Arctic Circle (about 66.5 degrees N) and below the Antarctic Circle (66.5 degrees S), the sun can stay above the horizon for a full 24 hours in summer (midnight sun or polar day) or remain below it all day in winter (polar night).

This happens mathematically when |cos(H)| exceeds 1 in the hour-angle formula, meaning no valid sunrise or sunset angle exists for that day.

The number of polar days and nights per year increases with latitude. At the North Pole itself, there is roughly six months of continuous daylight followed by six months of darkness.

Related Content

Related Tools

Earthquake Magnitude Calculator
Four modes: magnitude scales (Richter Mₗ, moment magnitude M𝑤, energy), energy comparison (each step = 31.6× more energy, logarithmic bar chart), Modified Mercalli Intensity I-XII with descriptions, and Richter magnitude from seismograph amplitude. Presets include Minor M3 through Great M8, 1906 San Francisco M7.9, and 2011 Japan M9.1.
Carbon Footprint Calculator
Estimate annual CO₂ emissions from transportation (car miles, fuel type, flights), home energy (electricity, heating, AC), diet (meat consumption, food waste), and lifestyle (shopping, recycling). Pie chart breakdown, country comparison bar chart, trees-to-offset and equivalent-driving metrics. Five presets: Average American, Eco-Conscious, Heavy Commuter, Frequent Flyer, Work from Home.
Star Lifecycle Visualizer
Three modes: interactive HR diagram with 23 real stars (click to see properties), stellar evolution pathway from nebula to end state (white dwarf, neutron star, or black hole based on initial mass), and star properties calculator (luminosity L∝M^3.5, radius, lifetime t∝M^-2.5, apparent magnitude). Six presets: Sun, Red Dwarf (0.3 M☉), Sirius A (2 M☉), Blue Giant (20 M☉), Betelgeuse (15 M☉), Supergiant (50 M☉). Includes spectral class colour strip and SVG star visualization.
H-R Diagram Explorer
Three modes: plot a single star on the Hertzsprung-Russell diagram from temperature, radius, and mass (Stefan-Boltzmann luminosity, spectral class O-M, absolute magnitude, HR region); compare multiple stars side by side; and browse the spectral atlas with typical properties for each class. 23 reference stars plotted, 6 presets from Proxima Centauri to Rigel.