Islamic prayer times

GET https://api.api.sh/calendar/v1/prayer-times
1 credit / call public data try it in the playground →

Prayer times for any place and date (up to 31 days): imsak, fajr, sunrise, dhuhr, asr, sunset, maghrib, isha and midnight in local time, with the Hijri date. Computed with the chosen method's published angles (default: the method used in the place's country), Standard or Hanafi Asr, and a high-latitude rule.

Every response includes credits_used: the credits this call cost.

Parameters

nametypedescription
lat number Latitude. Pass with lon; or use q, postal_code or geonameid.
lon number Longitude.
q string Place name, optionally with region and country: Cairo, Birmingham, GB. Example: Cairo
postal_code string Postal code, with country (default US).
country string Country for q or postal_code (ISO code or English name).
geonameid integer GeoNames id of a place (from /geo/v1/cities).
date string First date (YYYY-MM-DD, default today).
days integer Days, 1-31 (default 1).
method mwl | isna | egypt | makkah | karachi | tehran | jafari | gulf | kuwait | qatar | dubai | singapore | jakim | kemenag | turkey | france | russia | tunisia | algeria | morocco | jordan Calculation method (default by country, else MWL).
school standard | hanafi Asr: standard (Shafi, Maliki, Hanbali) or hanafi (default by country).
high_latitude angle_based | night_middle | one_seventh | none Rule where twilight never ends: angle_based (default), night_middle, one_seventh, none.

Every endpoint also takes fresh, raw, fields (see lean responses and caching).

Example

curl "https://api.api.sh/calendar/v1/prayer-times" \
  -H "x-api-key: $APISH_KEY"

Response

A JSON object with the fields described above, plus raw (the source's own data), cached, fetched_at and credits_used. Errors return {"success": false, "error": "…"} with the HTTP status (see errors). A lookup that ran but found nothing (404) costs the price above; refused calls and errors on our side are free (what's charged).

The fastest way to see the full response is the playground: it runs this endpoint with your account and shows the exact JSON.