Find where the Sun is in the sky for any location, date and time: its altitude above the horizon, its compass direction (azimuth) and how long shadows are. A chart traces the Sun's height through the whole day.
Last updated:
°
North positive, south negative
°
East positive, west negative
Any unit: the shadow uses the same unit
Enter your values to see the result.
Advertisement
Advertisement
How to use the Sun Position Calculator
Enter latitude and longitude in decimal degrees, pick a city preset, or press Use my location.
Choose the date and local time.
Pick the time zone of the place so the clock time matches.
Optionally enter an object height to get its shadow length.
Read the altitude, azimuth and shadow, then check the chart and hourly table.
Sun position formulas
Quantity
Formula
Hour angle H
H = 15° × (true solar time in hours − 12)
Altitude α
sin α = sin φ · sin δ + cos φ · cos δ · cos H
Azimuth A (from north)
A = atan2(sin H, cos H · sin φ − tan δ · cos φ) + 180°
Altitude at solar noon
αmax = 90° − |φ − δ|
Shadow length
L = h ÷ tan α
φ is latitude and δ the solar declination. True solar time is clock time corrected for your longitude within the time zone and for the equation of time. The calculator follows the NOAA solar calculator equations, which are accurate to roughly 0.01° in position for dates within a few centuries of today, and adds a standard atmospheric refraction correction.
Shadow length at common sun angles
Sun altitude
Shadow ÷ height
Shadow of a 1.8 m person
5°
11.43
20.6 m
10°
5.67
10.2 m
20°
2.75
4.95 m
30°
1.73
3.12 m
45°
1.00
1.80 m
60°
0.58
1.04 m
75°
0.27
0.48 m
Shadow angles are useful for planning solar panels and gardens, checking whether a building will shade a window, and photography. Panels facing the Sun's noon azimuth and tilted near your latitude collect the most energy over a year.
Frequently asked questions
What are solar altitude and azimuth?
Altitude (or elevation) is the Sun's angle above the horizon: 0° at sunrise or sunset and 90° directly overhead. Azimuth is the compass direction measured clockwise from true north: 90° east, 180° south, 270° west.
How is the sun angle calculated?
From the Sun's declination δ (its latitude on the sky, between about −23.44° and +23.44° through the year), your latitude φ and the hour angle H: sin(altitude) = sin φ sin δ + cos φ cos δ cos H. This calculator uses the NOAA solar position equations, accurate to a fraction of a degree.
How do I calculate shadow length from the sun angle?
Shadow length = object height ÷ tan(altitude). At 45° the shadow equals the height; at 30° it is 1.73 times the height and at 10° about 5.7 times. The shadow points directly away from the Sun, at the azimuth plus 180°.
Why is the sun not due south at 12:00?
Solar noon, when the Sun is highest and due south (or north in the southern hemisphere), depends on your longitude within the time zone, daylight saving time and the equation of time, which shifts it by up to about 16 minutes during the year.
Does the calculator include atmospheric refraction?
Yes. Refraction bends sunlight and lifts the Sun's apparent position, by about 0.57° at the horizon and much less higher up. The main altitude includes it; the steps also show the geometric altitude.
What is the highest the Sun gets at my location?
At solar noon the altitude is 90° − |latitude − declination|. At 40° N it is about 73.4° at the June solstice and 26.6° at the December solstice. The result card shows the maximum for the chosen date.
Is my location sent anywhere?
No. The Use my location button asks your browser for coordinates and all calculations run on your device; nothing is uploaded.
Are all the tools on FreeToolCabin tested for quality and accuracy?
Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.