Calendars API Reference
2 routes. Base URL https://api.apifor.dev, authenticated with x-api-key. Failed calls are not charged. Overview, limits and sources are on the Hijri calendar converter API page.
GET
/v1/calendars/hijri1 creditGregorian to Hijri (date), Hijri to Gregorian (hijri) or the months of a Hijri year (year). With country=ID the official government calendar is used where we hold it; otherwise the tabular Islamic calendar. Every response says which in `method`. 1 credit.
| Parameter | In | Type | Rules |
|---|---|---|---|
| date | query | string | Gregorian date to convert. Default: today. |
| hijri | query | string | Hijri date YYYY-MM-DD to convert to Gregorian. |
| year | query | integer | 1 to 1600 · Hijri year (1 to 1600) to list month by month. |
| country | query | string | ISO 3166-1 alpha-2 · ISO 3166-1 alpha-2. Selects an official calendar where one is held (coverage: ID). |
| calendar | query | string | one of umm-al-qura, tabular · umm-al-qura or tabular. Default: official for ID, umm-al-qura for SA, AE, QA, KW, BH, OM, tabular elsewhere. The response states the method. |
curl 'https://api.apifor.dev/v1/calendars/hijri?date=2026-11-28&hijri=1448-09-01&year=1448&country=ID' \
-H 'x-api-key: YOUR_API_KEY'{
"success": true,
"data": {
"country": "ID",
"official_coverage": [
"ID"
],
"gregorian_date": "2026-11-28",
"hijri": {
"year": 1448,
"month": 6,
"day": 18,
"month_name": "Jumada al-Akhirah",
"formatted": "18 Jumada al-Akhirah 1448 AH",
"local_month_name": "Jumadil Akhir"
},
"method": "official",
"method_note": "Official government calendar for ID."
},
"meta": {
"attribution": {
"source": "Kalender Hijriah Indonesia, Kementerian Agama Republik Indonesia (Ministry of Religious Affairs)",
"license": "Public domain (government calendar)",
"license_url": "https://kemenag.go.id",
"source_url": "https://bimasislam.kemenag.go.id",
"attribution_page": "https://apifor.dev/sources",
"notice": "Dates follow the published government calendar (MABIMS criteria). Final dates for Ramadan, Shawwal and Dhu al-Hijjah are set by the gover..."
}
}
}200Conversion400Invalid parameters
GET
/v1/calendars/coverageFreeCountries this service covers, with sources, licences, row counts and country-only fields. Free (0 credits), still needs an API key. Price note: Free.
curl 'https://api.apifor.dev/v1/calendars/coverage' \
-H 'x-api-key: YOUR_API_KEY'{
"success": true,
"data": {
"service": "calendars",
"global": true,
"country_param": "optional",
"param_name": "country",
"countries": [
{
"country": "ID",
"market": null,
"subdivision_levels": [],
"rows": null,
"updated_at": null,
"sources": [
{
"name": "Ministry of Religious Affairs Hijri calendar",
"url": "https://bimasislam.kemenag.go.id",
"licence": "Public domain (government calendar)",
"attribution": null
}
],
"local_fields": [],
"notes": "Official month starts where held; the tabular calendar elsewhere."
},
{
"country": "SA",
"market": null,
"subdivision_levels": [],
"rows": null,
"updated_at": null,
"sources": [
{
"name": "Umm al-Qura calendar table in ICU (via runtime Intl)",
"url": "https://github.com/unicode-org/icu",
"licence": "Unicode License v3",
"attribution": "Copyright © 2016-2025 Unicode, Inc."
}
],
"local_fields": [],
"notes": "Umm al-Qura (method umm-al-qura) by default for 1300-1600 AH; tabular outside. Religious dates follow moon sighting and can differ by a day."
}
]
}
}200Coverage