Sun Position Calculator: Sunrise, Sun Path, Solar Panel Angles
Pricing
Pay per event
Sun Position Calculator: Sunrise, Sun Path, Solar Panel Angles
Sun position from plain text for any place and time: elevation and azimuth, sunrise, sunset, solar noon, twilights, golden hour and shadows; yearly sun path diagrams with daily tables; solar panel tilt, clear-sky insolation and row spacing.
Pricing
Pay per event
Rating
0.0
(0)
Developer
Jumble Mog
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
3 hours ago
Last modified
Categories
Features
Share
The sun's position, sunrise and sunset, sun paths and solar panel angles from one line of text. Ask about a place and a time (sunrise, sunset and sun position in Denver on June 21, 2025 at 3 pm), a year (sun path for Sydney, Australia 2025) or a solar panel (solar panels in Phoenix tilted 25° facing south, panels 2 m long). Places are found by name from a built-in list of 69,000 towns and cities, and times come back in the local clock time, daylight saving included. You get back:
- Sun position: elevation (with atmospheric refraction) and azimuth at any moment, the compass direction, zenith, hour angle, declination, equation of time, air mass and clear-sky irradiance.
- The day's times: sunrise, sunset, solar noon and the noon elevation, day length, civil, nautical and astronomical dawn and dusk, the golden hour, and the sunrise and sunset directions. Midnight sun and polar night are recognised.
- Shadows: the length and direction of the shadow of a pole, tree or building of any height.
- Sun path for a year: a sun path diagram with clock-hour marks, sunrise and sunset for every day of the year (or one month), the solstice and equinox dates, the longest and shortest days and the earliest and latest sunrises and sunsets.
- Solar panel orientation: clear-sky insolation by month for any tilt and direction, the best fixed tilt, the angle of incidence at a given time, and the row spacing that keeps rows from shading each other on the winter solstice.
- A chart: the sun's elevation through the day with the twilight bands, the sun path diagram with daylight through the year, or insolation against tilt and by month.
It's made for:
- Architects and designers checking sun angles, shading and daylight for a site.
- Solar installers and homeowners comparing roof tilts and directions, and laying out ground-mounted rows.
- Photographers and filmmakers planning the golden hour and the sun's direction for a shoot.
- Gardeners, real-estate agents, surveyors and students, and AI agents that need correct sun times and angles for a place instead of a guess.

How to use it
- Write Places, dates and questions, one per entry. The form has examples.
- Optionally set the Units for shadow and panel lengths written without one (metric by default).
- Click Start. Each request is a row in the results, with its summary, chart and report.
What you can write
| You write | It means |
|---|---|
in Denver, Paris, Texas, Sydney, Australia, London Ontario, Perth WA | A town or city of 5,000+ people; add the country, US state or Canadian or Australian state when the name is shared (otherwise the largest is used) |
39.74, -104.99, 51.5N 0.12W, lat 39.74 lon -104.99, 33°52'S 151°13'E | Coordinates (the time zone is looked up from them) |
June 21, 2025, 2025-06-21, 21 June 2025, 6/21/2025, tomorrow | The date (no year = this year; no date = today) |
summer solstice 2025, winter solstice, march equinox | That day of the year, for the place's hemisphere |
at 3 pm, 15:30, noon, solar noon, now | The local time (no time with a date = solar noon; no date or time = now) |
6:30 UTC, 10:00 UTC+2, timezone America/Denver | A time in another zone, converted to local time, or the zone for the whole result |
golden hour, dawn and dusk, twilight | Puts those times first in the summary |
shadow of a 6 ft pole, a 30 m building, height 2 m | An object for the shadow |
sun path for Sydney 2025, every day in March 2026 | A year's sun path and daily table, or one month's days |
tilted 25°, 30 degree tilt, 6/12 roof | The panel tilt (no tilt = the best fixed tilt) |
facing south, southwest-facing, azimuth 200 | The panel direction (default: toward the equator) |
panels 2 m long, between 10 am and 2 pm, albedo 0.5 | Row spacing for panels of that slope length, the unshaded hours (default 9 am-3 pm solar time), ground reflectance |
The same as an object: {"place": "Cape Town", "date": "2025-12-21", "time": "12:00", "height": "2 m"}, {"lat": 51.5074, "lon": -0.1278, "time": "2025-03-20T10:00Z"}, {"type": "sunpath", "place": "Chicago", "year": 2026, "month": 3} or {"type": "panel", "place": "Munich", "tilt": 30, "azimuth": 180, "panelLength": "1.1 m", "hours": ["10:00", "14:00"]}.
Examples
sunrise, sunset and sun position in Denver on June 21, 2025 at 3 pm, shadow of a 6 ft pole→ 60.3° up at azimuth 245.7° (WSW); sunrise 05:32, solar noon 13:02 (73.7°), sunset 20:32, day length 14h 59m; a 3.43 ft shadow toward ENE.golden hour in San Francisco on 2025-10-01→ golden hour 07:06-07:40 and 18:17-18:52; sunrise 07:06, sunset 18:52.sun at 6:30 UTC in Tokyo on 2025-01-01→ 15:30 local, 10.9° up, azimuth 231.2° (SW); sunrise 06:51, sunset 16:39.sun path for Sydney, Australia 2025→ longest day Dec 21 (14h 25m), shortest Jun 20 (9h 54m); noon sun 32.7° to 79.6° up; earliest sunrise Oct 4 05:28 (the day before daylight saving starts), latest sunset Jan 7 20:10.sun in Tromso, Norway on 2025-06-21→ midnight sun: the sun stays up all day (43.8° at noon).solar panels in Phoenix tilted 25° facing south, panels 2 m long, row spacing→ clear-sky 2,460 kWh/m² a year, 99.7% of the best fixed tilt (30°); rows 3.62 m apart (a 1.8 m gap, ground coverage 0.55) leave no shade 9:00-15:00 solar time on the winter solstice.
How-to examples
Each example is a complete input; the results are from runs of the Actor (also listed under Examples).
How to find sunrise, sunset and the sun's position for a place and time
{"requests": ["sunrise, sunset and sun position in Denver on June 21, 2025 at 3 pm, shadow of a 6 ft pole"]}
Result: the sun is 60.3° up at azimuth 245.7° (WSW); sunrise 05:32, solar noon 13:02 (73.7°), sunset 20:32, a day length of 14h 59m, and a 3.43 ft shadow toward ENE.
How to find the golden hour for a photo shoot
{"requests": ["golden hour in San Francisco on 2025-10-01"]}
Result: golden hour 07:06-07:40 and 18:17-18:52; sunrise 07:06, sunset 18:52. Times are local, with daylight saving.
How to make a sun path diagram for a year
{"requests": ["sun path for Sydney, Australia 2025"]}
Result: a sun path diagram, with the longest day Dec 21 (14h 25m), the shortest Jun 20 (9h 54m), noon sun from 32.7° to 79.6° up, and the earliest sunrise Oct 4 05:28, the day before daylight saving starts.
How to let an AI agent answer sun questions
Add this Actor to the Apify MCP server with https://mcp.apify.com/?tools=jumblemog/sun-position-calculator. The agent passes the question as written and answers with exact times and angles for the place, instead of a guess.
FAQ
How accurate is it? It uses NOAA's solar calculator equations with refraction, checked against NREL's Solar Position Algorithm to within about 0.02° for 1800-2100. Near the poles, sunrise and sunset can be off by several minutes because refraction varies with the weather.
Do I need coordinates? No. Towns and cities of 5,000 or more people are found by name, with their time zones. Coordinates work anywhere.
Does it handle the midnight sun and polar night? Yes. "sun in Tromso, Norway on 2025-06-21" says the sun stays up all day.
Can it help with solar panels? Yes: clear-sky insolation for any tilt and direction, the best fixed tilt, and the row spacing that avoids shading on the winter solstice.
Does it work with Zapier, Make or n8n? Yes. Call the Actor with its Apify app or an HTTP request and pass the times on.
Input
| Field | What it is |
|---|---|
requests | The places and questions, as lines of text or objects (up to 200 per run) |
units | For shadow and panel lengths without a unit: metric (m) or us (ft) |
charts | Draw a chart for each request (default on) |
Output
One dataset item per request, also saved together in the run's OUTPUT record:
{"request": 1, "status": "ok", "type": "position", "title": "Sun in Denver, 2025-06-21","summary": "At 15:00 the sun is 60.3° up, azimuth 245.7° (WSW); sunrise 05:32, solar noon 13:02 (73.7°), sunset 20:32, day length 14h 59m; a 6 ft object casts a 3.43 ft shadow toward ENE.","place": {"name": "Denver", "country": "US", "latitude": 39.73915, "longitude": -104.9847, "timezone": "America/Denver"},"sun": {"time": "2025-06-21T15:00-06:00", "elevation": 60.255, "azimuth": 245.661, "direction": "WSW","zenith": 29.745, "hourAngle": 29.526, "declination": 23.436, "equationOfTime": -1.96, "airMass": 1.151,"clearSkyDirectNormal": 919, "clearSkyGlobalHorizontal": 890},"day": {"sunrise": "05:32", "sunset": "20:32", "solarNoon": "13:02", "noonElevation": 73.7, "dayLength": "14h 59m","civilDawn": "05:00", "civilDusk": "21:04", "goldenHourMorningEnd": "06:13", "goldenHourEveningStart": "19:51","sunriseAzimuth": 58.0, "sunsetAzimuth": 302.0, "utcOffset": -6,"iso": {"sunrise": "2025-06-21T05:32-06:00", "sunset": "2025-06-21T20:32-06:00", "...": "..."}},"shadow": {"height": 6, "length": 3.4285, "ratio": 0.5714, "direction": 65.66, "directionName": "ENE"},"data": [{"time": "00:00", "elevation": -25.19, "azimuth": 344.34}, "..."],"imageUrl": "https://api.apify.com/v2/key-value-stores/.../records/001-Sun-in-Denver-2025-06-21.png"}
Sun path results have year (key dates and extremes), months (the 21st of each month) and data (one row per day); panel results have panel (with rowSpacing and the angle of incidence at a time when you give one) and monthly. Every item has place, units, summary, warnings, notes (the method and every assumed value), a Markdown report and links to the chart and report. A request that can't be computed has "status": "failed" and the reason in error, and isn't billed.
How it works
- Sun position: the NOAA solar calculator equations from Meeus's Astronomical Algorithms (declination, equation of time, hour angle), with NOAA's refraction correction. Checked against NREL's Solar Position Algorithm: within about 0.02° for 1800-2100.
- Sunrise and sunset: the sun's upper edge on the horizon with standard refraction (zenith 90.833°), solved by iterating on the hour angle; twilights at 6°, 12° and 18° below the horizon and the golden hour at 6° above. Within a minute of SPA at mid-latitudes.
- Places and time zones: GeoNames towns of 5,000+ people matched by name and alternate names (accents and common spellings too), narrowed by country or state; coordinates get their time zone from timezone-boundary-builder's map; daylight saving from the IANA time zone database.
- Solar panels: clear-sky direct beam by Meinel (1361·0.7^(AM^0.678) W/m², Kasten-Young air mass), 10% diffuse with an isotropic sky and ground reflection, summed every 10 minutes over the year for each tilt from 0° to 90°.
- Row spacing: the gap that keeps each row's top edge (length × sin tilt) from shading the next row while the sun is between the given solar hours on the winter solstice: gap = height × cos(sun azimuth − panel azimuth) / tan(sun elevation).
Pricing
You pay one low price per request, at the prices shown on this page; a sun position with the day's times costs less than a year's sun path or a panel study. The chart and report are included. Requests that can't be computed are never charged. If you set a maximum cost per run, the Actor stops before a request that wouldn't fit.
Speed
A position takes a few milliseconds and a year's sun path or a panel study under half a second, after about 1.5 seconds to load the place list once per run. A run through the API answers in about 10 seconds, including the cloud container starting.
Tips and limits
- Clear-sky energy: the panel numbers leave out clouds, haze, temperature and inverter losses, so they compare tilts and directions; for expected production use a weather-based tool such as PVWatts or PVGIS.
- Near the poles refraction varies with the weather, so sunrise and sunset can be off by several minutes, and the first and last days of midnight sun or polar night may be a day off.
- Elevation and terrain: times are for a flat, sea-level horizon; mountains, buildings and the observer's height shift them.
- Shared place names: without a country or state the largest town of that name is used, and the result names the place it found; check
place. - Dates like 4/5/2025 are read month first, unless the first number is over 12.
- Limits: 200 requests per run; years 1800 to 2200.
For AI agents and developers
This Actor works with the Apify MCP server, so AI agents can call it as a tool. Pass requests as plain text and read summary, sun, day, shadow, year, panel and warnings. A direct API call that waits for the answer:
curl -X POST "https://api.apify.com/v2/acts/jumblemog~sun-position-calculator/run-sync-get-dataset-items?token=YOUR_TOKEN" \-H "Content-Type: application/json" \-d '{"requests": ["sunrise and sunset in Chicago tomorrow"]}'
run-sync instead returns the run's OUTPUT: the status, the counts and every result as JSON.
In Python, with the apify-client package:
from apify_client import ApifyClientclient = ApifyClient("YOUR_TOKEN")run = client.actor("jumblemog/sun-position-calculator").call(run_input={"requests": [{"lat": 48.8584, "lon": 2.2945, "date": "2025-06-21", "time": "18:00", "height": "330 m"}],})for item in client.dataset(run["defaultDatasetId"]).iterate_items():print(item["summary"])
Credits
- Places: GeoNames (CC BY 4.0) via geonamescache (MIT).
- Time zones: timezone-boundary-builder (ODbL) via timezonefinder (MIT), and the IANA database via tzdata (Apache-2.0).
- Math: NumPy (BSD-3-Clause); dates by dateutil (Apache-2.0/BSD).
- Charts: Vega-Lite and vl-convert (BSD-3-Clause), with the Inter font (SIL Open Font License).
- Methods: NOAA Global Monitoring Laboratory solar calculator; Meeus, Astronomical Algorithms (1998); Kasten and Young (1989) air mass; Meinel and Meinel (1976) clear-sky beam.