{"success":true,"version":"v1","request":{"tool":"get_calculator_schema","calculator_id":"sunrise-sunset"},"result":{"entity_type":"calculator","id":"sunrise-sunset","calculator_id":"sunrise-sunset","canonical_url":"https://tttkmbb.com/time/sunrise-sunset","name":"Sunrise and Sunset Calculator","title":"Sunrise and Sunset Calculator – Solar Noon, Day Length and Civil Twilight by NOAA Algorithm","category":"time","category_name":"Time & Geography","tool_name":"calculate_sunrise_sunset","featured_mcp_tool":false,"description":"Computes sunrise, sunset, solar noon, day length and civil twilight for any date, latitude and longitude with the NOAA Solar Calculator algorithm (Meeus-based solar position, equation of time, zenith 90.833° for refraction and the solar disc), reported in an IANA time zone.","use_when":"You need sunrise/sunset or daylight hours for a place and date, e.g. for photography, outdoor planning, solar energy or prayer-time style scheduling.","do_not_use_when":"You need minute-exact times for legal purposes, times at elevations far above sea level or with obstructed horizons, or moonrise/moonset (not covered); use moon-phase for the lunar phase.","inputs":[{"name":"date","label":"Date","type":"date","required":false,"default":"today","description":"Calendar date in time_zone (YYYY-MM-DD); defaults to the current UTC date.","example":"2026-09-23"},{"name":"latitude","label":"Latitude","type":"number","unit":"°","required":true,"min":-90,"max":90,"description":"Latitude in decimal degrees (north positive, south negative).","example":-34.9285},{"name":"longitude","label":"Longitude","type":"number","unit":"°","required":true,"min":-180,"max":180,"description":"Longitude in decimal degrees (east positive, west negative).","example":138.6007},{"name":"time_zone","label":"Time zone","type":"string","required":false,"default":"UTC","description":"IANA time zone for the reported times, normally the zone of the location (e.g. Australia/Adelaide). Defaults to UTC.","example":"Australia/Adelaide"}],"outputs":[{"name":"sunrise","label":"Sunrise","type":"string","decimals":4,"description":"Local time (HH:MM) the upper limb of the Sun appears; absent during polar day/night."},{"name":"sunset","label":"Sunset","type":"string","decimals":4,"description":"Local time (HH:MM) the upper limb disappears; absent during polar day/night."},{"name":"solar_noon","label":"Solar noon","type":"string","decimals":4,"description":"Local time the Sun crosses the meridian (highest point)."},{"name":"day_length","label":"Day length","type":"string","decimals":4,"description":"Time between sunrise and sunset as hours and minutes."},{"name":"day_length_hours","label":"Day length","type":"number","unit":"h","decimals":2,"description":"Day length in decimal hours (0 in polar night, 24 in polar day)."},{"name":"civil_twilight_begin","label":"Civil twilight begins","type":"string","decimals":4,"description":"Local time the Sun's centre is 6° below the horizon before sunrise (zenith 96°)."},{"name":"civil_twilight_end","label":"Civil twilight ends","type":"string","decimals":4,"description":"Local time the Sun's centre reaches 6° below the horizon after sunset."},{"name":"sunrise_utc","label":"Sunrise (UTC)","type":"string","decimals":4,"description":"Sunrise instant in UTC (ISO 8601)."},{"name":"sunset_utc","label":"Sunset (UTC)","type":"string","decimals":4,"description":"Sunset instant in UTC (ISO 8601)."},{"name":"solar_declination_degrees","label":"Solar declination","type":"number","unit":"°","decimals":2,"description":"Declination of the Sun at solar noon."},{"name":"equation_of_time_minutes","label":"Equation of time","type":"number","unit":"min","decimals":2,"description":"Apparent solar time minus mean solar time at solar noon."},{"name":"utc_offset","label":"UTC offset","type":"string","decimals":4,"description":"Offset of time_zone on that date (±HH:MM)."},{"name":"sun_status","label":"Sun status","type":"string","decimals":4,"description":"'Sun rises and sets', 'Polar day: Sun above the horizon all day' or 'Polar night: Sun below the horizon all day'."}],"input_schema":{"type":"object","properties":{"date":{"description":"Calendar date in time_zone (YYYY-MM-DD); defaults to the current UTC date.","type":"string","format":"date","default":"today","examples":["2026-09-23"]},"latitude":{"description":"Latitude in decimal degrees (north positive, south negative). Unit: °.","type":"number","minimum":-90,"maximum":90,"examples":[-34.9285],"x-unit":"°"},"longitude":{"description":"Longitude in decimal degrees (east positive, west negative). Unit: °.","type":"number","minimum":-180,"maximum":180,"examples":[138.6007],"x-unit":"°"},"time_zone":{"description":"IANA time zone for the reported times, normally the zone of the location (e.g. Australia/Adelaide). Defaults to UTC.","type":"string","default":"UTC","examples":["Australia/Adelaide"]}},"additionalProperties":false,"required":["latitude","longitude"]},"output_schema":{"type":"object","properties":{"sunrise":{"description":"Local time (HH:MM) the upper limb of the Sun appears; absent during polar day/night.","type":"string"},"sunset":{"description":"Local time (HH:MM) the upper limb disappears; absent during polar day/night.","type":"string"},"solar_noon":{"description":"Local time the Sun crosses the meridian (highest point).","type":"string"},"day_length":{"description":"Time between sunrise and sunset as hours and minutes.","type":"string"},"day_length_hours":{"description":"Day length in decimal hours (0 in polar night, 24 in polar day). Unit: h.","type":"number","x-unit":"h"},"civil_twilight_begin":{"description":"Local time the Sun's centre is 6° below the horizon before sunrise (zenith 96°).","type":"string"},"civil_twilight_end":{"description":"Local time the Sun's centre reaches 6° below the horizon after sunset.","type":"string"},"sunrise_utc":{"description":"Sunrise instant in UTC (ISO 8601).","type":"string"},"sunset_utc":{"description":"Sunset instant in UTC (ISO 8601).","type":"string"},"solar_declination_degrees":{"description":"Declination of the Sun at solar noon. Unit: °.","type":"number","x-unit":"°"},"equation_of_time_minutes":{"description":"Apparent solar time minus mean solar time at solar noon. Unit: min.","type":"number","x-unit":"min"},"utc_offset":{"description":"Offset of time_zone on that date (±HH:MM).","type":"string"},"sun_status":{"description":"'Sun rises and sets', 'Polar day: Sun above the horizon all day' or 'Polar night: Sun below the horizon all day'.","type":"string"}}},"formula":"cos(HA) = cos(90.833°) / (cos φ · cos δ) − tan φ · tan δ; sunrise_UTC = 720 − 4 · (longitude + HA) − EoT minutes; sunset_UTC = 720 − 4 · (longitude − HA) − EoT; solar_noon_UTC = 720 − 4 · longitude − EoT; civil twilight uses zenith 96°","method":"Implements NOAA's spreadsheet/JavaScript algorithm: solar declination δ and equation of time EoT from the Julian century (Meeus), one refinement pass at the estimated event time, refraction and solar radius folded into the 90.833° zenith. Accuracy is about ±1 minute for latitudes up to ±72° (±10 minutes nearer the poles); results are the events that fall on the given calendar date in time_zone.","sources":[{"name":"NOAA Global Monitoring Laboratory – Solar Calculator: calculation details","url":"https://gml.noaa.gov/grad/solcalc/calcdetails.html","type":"government","retrieved_at":"2026-09-24"},{"name":"NOAA – General Solar Position Calculations (solareqns.pdf)","url":"https://gml.noaa.gov/grad/solcalc/solareqns.PDF","type":"government","retrieved_at":"2026-09-24"},{"name":"Sunrise equation (Wikipedia)","url":"https://en.wikipedia.org/wiki/Sunrise_equation","type":"reference","retrieved_at":"2026-09-24"}],"freshness":{"type":"daily","max_age_seconds":86400,"note":"Depends on the current date unless the date is supplied."},"examples":[{"name":"Adelaide (−34.9285, 138.6007) on 2026-09-23","inputs":{"date":"2026-09-23","latitude":-34.9285,"longitude":138.6007,"time_zone":"Australia/Adelaide"},"expected":{"sunrise":"06:04","sunset":"18:12","solar_noon":"12:08","civil_twilight_begin":"05:39","civil_twilight_end":"18:38","sunrise_utc":"2026-09-22T20:34:00Z","utc_offset":"+09:30","sun_status":"Sun rises and sets"},"url":"https://tttkmbb.com/api/v1/calculate/sunrise-sunset?date=2026-09-23&latitude=-34.9285&longitude=138.6007&time_zone=Australia%2FAdelaide"},{"name":"London (51.5074, −0.1278) on the June solstice 2026","inputs":{"date":"2026-06-21","latitude":51.5074,"longitude":-0.1278,"time_zone":"Europe/London"},"expected":{"sunrise":"04:43","sunset":"21:22","solar_noon":"13:02","day_length":"16 h 38 min","day_length_hours":16.63,"civil_twilight_begin":"03:55","civil_twilight_end":"22:09","solar_declination_degrees":23.44},"url":"https://tttkmbb.com/api/v1/calculate/sunrise-sunset?date=2026-06-21&latitude=51.5074&longitude=-0.1278&time_zone=Europe%2FLondon"}],"faq":[{"q":"Why do published times sometimes differ by a minute?","a":"Almanacs round differently and use slightly different refraction models; NOAA's method is accurate to about one minute at mid-latitudes. Local terrain, elevation and atmospheric conditions can shift the observed event by several minutes."},{"q":"What happens inside the polar circles?","a":"When the Sun stays above (polar day) or below (polar night) the horizon all day, sunrise and sunset are omitted, sun_status explains why and day_length_hours is 24 or 0. Civil twilight is still reported when it occurs."}],"tags":["sunrise","sunset","sunrise time","day length","solar noon","civil twilight","daylight hours"],"related":[{"calculator_id":"moon-phase","reason":"Lunar phase and illumination for the same date."},{"calculator_id":"time-zone-converter","reason":"Express the sunrise time in another zone."},{"calculator_id":"julian-date","reason":"Julian Date used internally by the solar position formulas."}],"links":{"html":"https://tttkmbb.com/time/sunrise-sunset","markdown":"https://tttkmbb.com/time/sunrise-sunset.md","json":"https://tttkmbb.com/time/sunrise-sunset.json","api":"https://tttkmbb.com/api/v1/calculate/sunrise-sunset","schema":"https://tttkmbb.com/api/v1/calculators/sunrise-sunset","openapi":"https://tttkmbb.com/openapi.json","mcp":"https://tttkmbb.com/mcp"},"version":"v1","updated_at":"2026-09-24"},"timestamp":"2026-09-24T01:59:34Z","next_actions":[{"tool":"run_calculator","calculator_id":"sunrise-sunset","reason":"Run Sunrise and Sunset Calculator with the inputs above."}],"links":{"markdown":"https://tttkmbb.com/time/sunrise-sunset.md"}}