Back to Time
Sunrise & Sunset Calculator

Sunrise & Sunset Calculator

Enter a latitude, longitude and date to compute sunrise, sunset, solar noon, day length and the sun's noon altitude for that location. Also finds civil, nautical and astronomical twilight (dawn and dusk). Includes presets for major cities. A NOAA-style astronomical approximation that runs entirely in your browser.

timecalculator

How to use

Pick a city preset or type a latitude and longitude directly, then choose a date and a UTC offset to compute sunrise, sunset, solar noon (when the sun is highest, due south), day length and the sun's noon altitude for that place and day. It also shows the times of civil, nautical and astronomical twilight — the glow before dawn and after dusk. Editing the latitude or longitude by hand switches the preset to Custom. Displayed times are local clock times for the chosen UTC offset. It's a NOAA-style astronomical approximation that runs entirely in your browser.

FAQ

Is my input uploaded anywhere?
No. Everything is computed in your browser via local JavaScript — the latitude, longitude and date you enter never leave your device.
What is the UTC offset and what should I enter?
It's the time difference from Coordinated Universal Time (UTC), in hours. For Japan, use +9 (Japan Standard Time). For other places, enter that region's standard offset (e.g., New York −5, London 0, Sydney +10). The sunrise and sunset times shown are local clock times for that offset.
Is daylight saving time applied?
No. The UTC offset is used exactly as entered, with no automatic DST switching. During summer time, enter the region's offset advanced by one hour (e.g., New York is −4 in summer).
What are solar noon and noon altitude?
Solar noon is the moment the sun is highest in the sky that day (crossing nearly due south), i.e., true solar midday. Noon altitude is the sun's angle above the horizon at that moment, in degrees. It depends on latitude and season (the sun's declination).
How do civil, nautical and astronomical twilight differ?
Twilight is the dim light before sunrise and after sunset. While the sun is up to 6° below the horizon it's civil twilight (bright enough to read outdoors); up to 12° is nautical twilight (the horizon is still distinguishable); up to 18° is astronomical twilight (darker than this is full night). "Dawn (begins)" is when that light starts in the morning; "Dusk (ends)" is when it ends in the evening.
How accurate is it?
It's an approximation that includes standard atmospheric refraction, usually within about a minute of the true value. At high latitudes, or where hills or buildings block the horizon, the actual visible times can differ more.
Why does it sometimes say midnight sun or polar night?
At high latitudes the sun can stay above the horizon all day in summer (midnight sun) or below it all day in winter (polar night). In those cases there is no sunrise or sunset time, so a dedicated message is shown instead.

Related tools