Sunrise Calculator — Sunrise & Sunset Times
Calculate sunrise, sunset, and day length for any location and date. Find golden hour times for photography and plan your day with solar data.
Formula
Cos(HourAngle) = -Tan(Lat) × Tan(Dec)
Uses spherical trigonometry based on your latitude and the sun's declination (seasonal angle) to find the hour angle when the sun crosses the horizon.
Worked Examples
Example 1: New York Summer Solstice
Problem:NYC (40.7°N) on June 21.
Solution:Day Length: ~15 hours Sunrise: ~5:25 AM Sunset: ~8:30 PM Result: Longest day of the year.
Result:~15h 5m Daylight
Example 2: London Winter Solstice
Problem:London (51.5°N) on Dec 21.
Solution:Day Length: ~7 hours 50 mins Sunrise: ~8:00 AM Sunset: ~3:50 PM Result: Shortest day of the year.
Result:~7h 50m Daylight
Frequently Asked Questions
Why do sunrise and sunset times change daily?
The Earth revolves around the Sun while tilted on its axis (23.5°). This tilt means the angle of the Sun changes slightly every day relative to your location, causing the days to get longer or shorter depending on the season.
What is 'Golden Hour'?
Golden Hour is the period shortly after sunrise or before sunset. The sun is low in the sky, creating soft, diffused, warm light that is perfect for photography and cinematography. It lacks the harsh shadows of midday sun.
What is 'Solar Noon'?
Solar Noon is the moment when the Sun reaches its highest point in the sky for the day. It rarely matches 12:00 PM on your clock due to time zones and Daylight Saving Time. At solar noon, shadows are shortest.
How does latitude affect day length?
Latitude determines how much seasonal variation you experience. At the equator (0°), days are ~12 hours long year-round. At the poles (90°), you can have 24 hours of daylight (Midnight Sun) or 24 hours of darkness (Polar Night).
What is Blue Hour?
Blue Hour occurs just before sunrise and just after sunset, when the sun is below the horizon. The sky takes on a deep blue hue. It is prized by photographers for cityscapes and landscapes.
Why is the earliest sunset not on the shortest day?
This is due to the 'Equation of Time'—the difference between clock time and solar time caused by Earth's elliptical orbit and axial tilt. The earliest sunset typically happens a few weeks before the Winter Solstice, and the latest sunrise a few weeks after.
What are Civil, Nautical, and Astronomical Twilights?
These define stages of darkness based on the sun's angle below the horizon. Civil (0-6°): Streetlights needed. Nautical (6-12°): Horizon visible at sea. Astronomical (12-18°): Totally dark sky for stargazing.
Do longitude coordinates affect sunrise time?
Yes. For every degree of longitude you move west within a time zone, sunrise and sunset occur about 4 minutes later. This explains why the sun sets much later in western parts of a time zone compared to eastern parts.
What is the longest day of the year?
The Summer Solstice (around June 21 in Northern Hemisphere, Dec 21 in Southern). It has the maximum daylight hours. Conversely, the Winter Solstice is the shortest day.
Background & Theory
The Mechanics of Day & Night:
1. Rotation: Earth spins once every 24 hours, creating the day/night cycle.
2. Revolution: Earth orbits the Sun once every 365.25 days.
3. Axial Tilt (23.5°): This is the key factor. The Earth doesn't spin "straight up" relative to its orbit. It leans.
- Summer: Your hemisphere tilts TOWARD the sun → Sun path is higher and longer → Longer days.
- Winter: Your hemisphere tilts AWAY from the sun → Sun path is lower and shorter → Shorter days.
Solar Noon vs. Clock Noon:
Our clocks are averaged (Mean Solar Time). The actual sun varies because Earth's speed changes in its elliptical orbit (faster when closer to sun). The difference is called the "Equation of Time" and can be up to ±16 minutes.
Atmospheric Refraction:
The atmosphere acts like a lens, bending light. We can actually see the sun before it physically rises and after it physically sets. Standard sunrise/sunset definitions account for this refraction (typically 0.833 degrees correction).