Sunrise and sunset

When does the sun rise and set where you are, or anywhere, on any date? With dawn and dusk, the length of the day, and the directions of sunrise and sunset drawn on the map.

How to use it

  1. Choose a place: search, use your location, or click the map.
  2. Choose the date. Use the arrows for the day before or after.
  3. Read sunrise, sunset, solar noon and the twilights in local time. The lines on the map show where the sun rises and sets.

5 practical uses

  1. Plan a hike, a run or a ride around daylight.
  2. Time a photo of a sunrise or a sunset.
  3. Set the lighting or the opening hours of a business or a park.
  4. Know when to stop fishing, flying or sailing.
  5. Plan a road trip so the driving is in daylight.

The maths behind it

The sun's position is found from the Julian day: the mean anomaly and the ecliptic longitude give the declination δ and right ascension; with the local sidereal time they give the hour angle. Sunrise and sunset are the times when the sun's centre is at −0.833° altitude (the sun's radius plus refraction), from cos H = (sin h − sin φ sin δ) / (cos φ cos δ); the twilights use −6°, −12° and −18°. Solar noon is the transit, when the hour angle is zero.

The twilights

Civil twilight (sun less than 6° below the horizon) is bright enough to read outdoors; nautical (6° to 12°) shows the horizon at sea but not much else; astronomical (12° to 18°) is dark to the eye but the sky still glows for a telescope. Inside the polar circles the sun may not rise or set at all on some dates, and near them twilight can last all night in summer; the tool says so.

Times are computed in the browser with the SunCalc library, which follows the astronomical almanac formulas to within a minute or so, and are shown in the local time of the place, including summer time, from its time zone. Sunrise and sunset are the moments the top edge of the sun meets a flat horizon, with the usual allowance for the bending of light in the air; a hill to the east delays your sunrise.

Questions and answers

Are the times in local time?

Yes, in the local time of the place, summer time included, from its time zone.

What are civil, nautical and astronomical twilight?

The sun 6, 12 and 18 degrees below the horizon. Civil twilight is bright enough to read outdoors; nautical shows the horizon at sea; astronomical is dark to the eye.

Why no sunrise today?

Inside the polar circles the sun may not rise or set on some dates. The page says whether it is the midnight sun or the polar night.

Embed this tool on your website

Paste this code where the tool should appear. It shows the tool alone, without this page's text, and links back here. It is free to use; the map data credit stays on the map.

<iframe src="https://waymorphic.com/tools/sunrise-sunset?embed=1" width="100%" height="760" style="border:0;border-radius:12px;max-width:100%" loading="lazy" allow="geolocation; fullscreen; clipboard-write" title="Sunrise and sunset – Waymorphic Map"></iframe>

Change height to suit your page. To open the tool with a place already set, add the settings from this page's address bar (the part after #) to the end of the src. The embedded tool asks the visitor's browser for their location only when they press the button, and the allow attribute lets that work inside the frame.