Sunrise & Sunset Calculator

Sunrise, sunset, golden hour and twilight times for any place and date, computed from your coordinates rather than a nearby city.

A sundial and a clock disagree by half an hour over the year

The Earth's orbit is an ellipse and its axis is tilted, so the real Sun runs ahead of the clock for part of the year and behind it for the rest. The difference is called the equation of time, and both sunrise and sunset carry it.

DateSun is
1 Jan 3.6 min behind the clock
13 Feb 14.6 min behind the clock
15 Apr 0.2 min behind the clock
15 Jun 0.2 min behind the clock
19 Jul 6.0 min behind the clock
17 Sep 6.4 min ahead of the clock
30 Oct 16.5 min ahead of the clock
31 Dec 3.6 min behind the clock

It peaks at 16.5 minutes ahead in early November and 14.6 behind in mid-February — a full swing of 31 minutes. Solar noon, the moment the Sun is actually highest, wanders across that same 31 minutes of clock time. It crosses zero four times a year, which is why a sundial agrees with a watch on exactly four days and is wrong on the other 361.

Which is why the earliest sunset is not on the shortest day

In December the day is still shortening, but solar noon is drifting later. Those two fight: shortening pulls sunset earlier, drifting noon pushes it later. Sunset stops getting earlier as soon as the drift wins — and that happens before the solstice.

LatitudeEarliest sunsetLatest sunrise
25° 24 days before the solstice 24 days after
40° 15 days before the solstice 10 days after
51° 10 days before the solstice 9 days after
60° 6 days before the solstice 5 days after

The shortest day itself is always the solstice; it is the sunset and sunrise that move away from it in opposite directions. The gap shrinks the further north you go, from 24 days near the tropics to 6 at 60°, because up there the day is shortening fast enough in December to overwhelm the drift almost until the solstice. So for roughly 25 days around midwinter at mid-latitudes, the evenings are already drawing out while the mornings are still getting darker. Both are true at the same time, and neither is what "the days get longer after the 21st" describes.

Why the two effects can trade places at all

The word "solstice" means the Sun standing still, and the arithmetic bears it out: at 40°N the day length changes by 0.04 minutes from one day to the next around the solstice, against 2.7 minutes around the equinox. Meanwhile solar noon is drifting by about 0.5 minutes a day — larger than the daylight change, which is exactly why it can win. Near an equinox the daylight change is many times the drift and no such swap is possible. That is the whole mechanism: two effects of similar size pulling opposite ways, for a few weeks a year, in one part of the calendar only. It is also why a table like the one above is worth reading rather than estimating.

How to use

  1. Set your exact location.
  2. Pick a date.
  3. Read sunrise, sunset and the twilight windows.
  4. Allow for terrain, which the calculation cannot see.

Frequently asked questions

What is golden hour?

The period shortly after sunrise and before sunset when the sun is low and its light is warm, soft and directional. It is not literally an hour — its length depends on latitude and season, and near the poles it can last for hours while in the tropics it is brief.

What is blue hour?

The twilight period when the sun is below the horizon but the sky still holds a deep blue light. It follows sunset and precedes sunrise, and it is favoured for cityscapes because artificial lights balance against the remaining sky brightness.

What are the three twilights?

Civil twilight lasts until the sun is 6 degrees below the horizon and there is enough light for most outdoor activity. Nautical twilight extends to 12 degrees, where the horizon is still discernible at sea. Astronomical twilight reaches 18 degrees, after which the sky is fully dark.

Why is the calculated sunset later than what I see?

Because the calculation assumes a flat horizon at sea level. Hills, buildings and trees block the sun well before it reaches the true horizon, so the practical sunset in a valley can be substantially earlier. Elevation works the other way — from a summit you see the sun for longer.

Why is the earliest sunset not on the shortest day?

Because of the equation of time, which comes from the Earth's tilted axis and elliptical orbit. Earliest sunset falls before the solstice and latest sunrise after it, so the shortest day is the shortest total daylight without being either extreme.

Does refraction affect the times?

Yes, and it is built into the standard calculation. The atmosphere bends light, so the sun is already geometrically below the horizon when you see it set — by roughly its own diameter. The sunset you watch has, strictly, already happened.

🌐 This tool looks up results using the free Open-Meteo geocoding API. The word you enter is sent to that service to fetch results; nothing is stored by this site.