Skip to main content
All providers

Sunrise-Sunset

Geo

api.sunrise-sunset.org

Sunrise, sunset, solar noon and twilight times for any coordinate and date.

Capabilities (3)

GET /v1/data/sunrisesunset/almanac1 credit

Full day of sun and moon data for one coordinate: sunrise, sunset, solar noon, day length in seconds, the three twilight pairs, dawn/dusk, first and last light, golden hour and blue hour as morning/evening begin-end pairs, sunrise/sunset/noon azimuth and noon altitude in degrees, plus moonrise, moonset, moon phase and illumination percentage, all in ISO 8601 with the local UTC offset.

latlngdate?tz?time_format?
GET /v1/data/sunrisesunset/almanac-range1 credit

The same per-day sun and moon record as the single-day call, but as a days array covering every date from date_start to date_end inclusive, with tzid, lat and lng hoisted to the top level once.

latlngdate_startdate_endtz?time_format?
GET /v1/data/sunrisesunset/times1 credit

The original endpoint: sunrise, sunset, solar noon, day length and the civil, nautical and astronomical twilight boundaries for one coordinate on one date, defaulting to 12-hour AM/PM strings in UTC.

latlngdate?formatted?tzid?

Licence

Free to use with no key, for reasonable request volumes. Attribution is required: display a visible link to sunrise-sunset.org wherever the data is shown. No commercial restriction is stated.

https://sunrise-sunset.org/api

Attribution

Display this wherever you show the data. It arrives on every response as provenance.attribution_text.

Sunrise-Sunset.org (https://sunrise-sunset.org)

Cache: up to 86400s