Dates and conversion
How to Convert a Gregorian Date to a Hijri Date
Convert any Gregorian date to the Hijri calendar: a quick formula accurate to about two days, the exact converter method, and a month-table check.
By Tahir Nasuru · · 8 min read

To convert a Gregorian date to a Hijri date, you find which Islamic lunar month and year that day falls in. The exact way is to use a converter built on a published Hijri calendar, such as Saudi Arabia's calculated Umm al-Qura calendar. Without one, a short formula gets you within about two days, and a table of month start dates lets you check the result by counting. For example, Monday 9 November 2026 is 29 Jumada al-Awwal 1448 in the calculated Umm al-Qura calendar.
Key Takeaways
- For the year alone, AH ≈ (CE − 622) × 33 ÷ 32. Every Gregorian year overlaps two Hijri years, and occasionally three, so the result can be one year off.
- A formula based on the average year and month length gives the full date to within two days, and exactly right a little over half the time.
- For an exact answer, use a converter and check it against a table of the first day of each Hijri month.
- Calculated dates can differ by a day from a locally announced month, and the Islamic day begins at sunset.
Why there is no simple one-line conversion
The two calendars count different things. The Gregorian calendar follows the sun, while the Hijri calendar follows the moon. The Quran describes the moon's ordained phases as given "so that you may know the number of years and calculation ˹of time˺" (Quran 10:5, The Clear Quran translation of the meaning on quran.com).
A Hijri month lasts 29 or 30 days. In Sahih al-Bukhari 1913, the Prophet ﷺ describes the month as "sometimes of 29 days and sometimes of thirty days." Twelve such months make a year of 354 or 355 days, about 11 days shorter than a Gregorian year. The US Naval Observatory notes that the cycle of twelve Islamic months moves through the seasons "over a period of about 33 years."
Which months have 29 days is not fixed. In the calculated Umm al-Qura calendar, 1448 AH has 29 days in Muharram and 30 in Safar, while 1447 AH had the reverse. So you cannot simply alternate 30 and 29 and expect to land on the published date. The sister post on why months have 29 or 30 days explains where that variation comes from.
Method 1: estimate the Hijri year
The Hijri count starts at 1 Muharram 1 AH, which the US Naval Observatory's Islamic calendar page gives as Friday 16 July 622 CE in the Julian calendar. Because 33 Hijri years take roughly as long as 32 Gregorian years, the year can be estimated with one line:
AH ≈ (CE − 622) × 33 ÷ 32
For 2026: (2026 − 622) × 33 ÷ 32 = 1404 × 1.03125 = 1447.9.
The answer is 1447 or 1448, and that is the honest error bound for this shortcut. A Gregorian year always spans parts of two Hijri years. In the calculated Umm al-Qura calendar, 1 January 2026 is 12 Rajab 1447 and 31 December 2026 is 22 Rajab 1448. The Hijri year changes at 1 Muharram, which in 2026 falls on 16 June. Dates before that are in 1447, and dates after it are in 1448.
Sometimes a Gregorian year touches three Hijri years. 1 January 2008 is 22 Dhu al-Hijjah 1428, and 31 December 2008 is already 3 Muharram 1430, so all of 1429 AH fits inside 2008.
We checked the shortcut for every Gregorian year from 1925 to 2076. Rounded down, the result was always one of the Hijri years that overlap that Gregorian year. It never tells you which one, so use Method 2 or 3 when the date is anywhere near the Islamic New Year.
Method 2: approximate the full date with a formula
To get the month and day as well, use the average lengths of the two years. The Gregorian leap-year rule, which the USNO calendar page sets out, gives 97 leap days every 400 years, so the average Gregorian year is 365.2425 days. The arithmetical Islamic calendar has 10,631 days in 30 years, as R.H. van Gent of Utrecht University shows on his page on the mathematics of the 30-year cycle. That is 354.367 days per year. The ratio of the two is about 1.03069.
The epoch, 16 July 622 in the Julian calendar, is 19 July 622 in the Gregorian calendar extended backwards. That is about 0.54 of the way through the year 622.
The steps are:
- Turn the date into a decimal year. Take the day of the year (1 January is day 1), subtract 1, divide by 365.25, and add the year.
- Count Hijri years. Subtract 622.54 and multiply by 1.03069.
- Read the year. Add 1 to the whole-number part. This is the Hijri year.
- Find the day of the Hijri year. Multiply the fractional part by 354.37.
- Find the month. Divide that by 29.53. The whole number is the count of months already finished, so add 1 to get the month number.
- Find the day. Subtract (finished months × 29.53) from the day of the year, drop the fraction and add 1.
The constants matter. Rounding 1.03069 to 1.0307 sounds harmless, but over 1,400 years it moves the answer by about five days.
Worked example: Monday 9 November 2026
- 9 November is day 313 of 2026. 2026 + 312 ÷ 365.25 = 2026.8542.
- (2026.8542 − 622.54) × 1.03069 = 1404.3142 × 1.03069 = 1447.4126.
- Year: 1447 + 1 = 1448.
- 0.4126 × 354.37 = 146.22 days into the year.
- 146.22 ÷ 29.53 = 4.95, so 4 months are finished: month 5, Jumada al-Awwal.
- 146.22 − (4 × 29.53) = 28.10, so the day is 28 + 1 = 29.
The estimate is 29 Jumada al-Awwal 1448, which matches the calculated Umm al-Qura date exactly.
Worked example: Saturday 1 June 2030
- 1 June is day 152 of 2030. 2030 + 151 ÷ 365.25 = 2030.4134.
- (2030.4134 − 622.54) × 1.03069 = 1451.0811.
- Year: 1452.
- 0.0811 × 354.37 = 28.72 days into the year.
- 28.72 ÷ 29.53 = 0.97, so no month is finished yet: month 1, Muharram.
- The day is 28 + 1 = 29.
The estimate is 29 Muharram 1452. The calculated Umm al-Qura date is 30 Muharram 1452, so the formula is one day short. This is the typical failure: near the end of a month, the average month length cannot tell whether that particular month has 29 or 30 days.
How accurate the formula is
We ran the six steps for every day from 1 January 1925 to 31 December 2076 and compared each result with the Umm al-Qura date. The formula was exactly right on 57% of days and within one day on 98%. It was never more than two days off. Those bounds hold only for this range. Outside it there is no Umm al-Qura data to compare with, and far from the present the small errors in the constants slowly add up.
Method 3: use a converter, then check it with a month table
For anything you will write down, such as a document, an invitation or a record, use a converter. The Hijri date converter on this site uses the open-source hijri-converter library, which is based on the Umm al-Qura calendar and covers 1343 to 1500 AH (1 August 1924 to 16 November 2077 CE). R.H. van Gent describes Umm al-Qura as a calculated lunar calendar that Saudi Arabia has used for several decades, rather than one based on sighting the crescent.
You can check any converter result by hand with a table of month start dates. Find the month whose first day falls on or before your date, count the days after it, and add 1.
| No. | Month (1448 AH) | 1st day (calculated) | Days |
|---|---|---|---|
| 1 | Muharram | 16 June 2026 | 29 |
| 2 | Safar | 15 July 2026 | 30 |
| 3 | Rabi al-Awwal | 14 August 2026 | 29 |
| 4 | Rabi al-Thani | 12 September 2026 | 30 |
| 5 | Jumada al-Awwal | 12 October 2026 | 30 |
| 6 | Jumada al-Thani | 11 November 2026 | 29 |
| 7 | Rajab | 10 December 2026 | 30 |
| 8 | Sha'ban | 9 January 2027 | 30 |
| 9 | Ramadan | 8 February 2027 | 29 |
| 10 | Shawwal | 9 March 2027 | 30 |
| 11 | Dhu al-Qi'dah | 8 April 2027 | 29 |
| 12 | Dhu al-Hijjah | 7 May 2027 | 30 |
Dates in this table and in the examples are calculated from the Umm al-Qura tables in the open-source hijri-converter library behind the converter. The monthly Hijri calendar pages show the same start dates for each month.
Worked example: Friday 25 December 2026
Rajab 1448 begins on 10 December 2026, and Sha'ban does not begin until 9 January 2027. 25 December is 15 days after 10 December, so the date is 15 + 1 = 16 Rajab 1448. The converter gives the same answer.
The same check confirms the first example. 1 Jumada al-Awwal is 12 October 2026, and 9 November is 28 days later, which makes it 29 Jumada al-Awwal. The table also shows that Jumada al-Awwal 1448 has 30 days, so 10 November 2026 is 30 Jumada al-Awwal and the next month begins on 11 November.
Two things a converter cannot tell you
Your local announcement. A calculated calendar is fixed in advance. Many communities start Ramadan, Eid and other months from a crescent sighting or an announcement, and the hijri-converter project itself says it is not intended for religious purposes where sighting is preferred. Van Gent notes that dates observed around Ramadan and Dhu al-Hijjah can differ from the calculated calendar by one to three days. Which method to follow is a question for qualified scholars and your local mosque. The sister post on why converters disagree by a day covers the other calendars you may meet.
Which evening the day starts. Islamic dates begin at sunset, while a converter matches whole civil days. An event on the evening of Monday 9 November 2026, after sunset, falls in the Islamic day of 30 Jumada al-Awwal 1448, the date the converter gives for Tuesday 10 November. If a time of day matters, as with a birth after sunset, decide which convention you are using and write it down. The post on the Islamic day beginning at sunset explains the convention.
Convert your own date
- Enter the Gregorian date in the date converter and note the Hijri date it gives.
- If you need a rough figure without a device, use Method 1 for the year or Method 2 for the full date, and treat the answer as correct to within two days.
- Check the converter result against the month table for that year, especially near the end of a month.
- If the date is for worship, confirm the month start with the authority you follow, and if the moment was after sunset, move to the next Hijri day.


