Learn how we predict crescent moon visibility using astronomy and machine learning
Hilal is the Arabic term for the thin crescent moon that appears shortly after the astronomical new moon (conjunction). In Islam, the sighting of the Hilal marks the beginning of a new lunar month.
The Islamic (Hijri) calendar is a purely lunar calendar consisting of 12 months of 29 or 30 days each. Because each month begins with the actual sighting of the crescent moon, accurate prediction of Hilal visibility is essential for determining the start of important months like Ramadan (the month of fasting), Shawwal (Eid al-Fitr), and Dhul Hijjah (Hajj and Eid al-Adha).
The crescent is typically looked for on the 29th evening of the current Islamic month, just after sunset. If the Hilal is sighted, the new month begins that evening. If not, the current month completes 30 days and the new month begins the following evening.
Our system calculates seven key astronomical parameters at the moment of sunset for a given location and date. These parameters determine whether the crescent moon is geometrically positioned to be visible to the naked eye.
The time difference (in minutes) between sunset and moonset. A longer lag means the crescent moon stays visible above the horizon for more time after the sky darkens, improving the chance of sighting.
The number of hours elapsed since conjunction (new moon). The moon needs sufficient time after conjunction to move away from the sun and develop a visible crescent. Very young moons (under ~15 hours) are virtually impossible to see.
The angular height of the moon above the horizon at sunset (in degrees). Higher altitude means the crescent is farther from the glare of the horizon and easier to spot against the darkening sky.
The angular separation between the sun and moon as seen from the observer. Greater elongation means more of the moon's illuminated surface faces the observer, making the crescent brighter and easier to see.
The percentage of the moon’s visible surface that is illuminated by the sun (0\u2013100%). At conjunction it is 0%; for a new crescent it is typically between 0.5% and 3%. Even a small increase in illumination significantly improves naked-eye visibility.
The altitude difference between the Moon and the Sun at sunset (in degrees). A larger ARCV means the Moon is higher above the Sun’s position, placing the crescent in a darker part of the sky where it is easier to detect against the twilight glow.
The angular width of the illuminated crescent (in arcminutes), computed from the Moon’s angular semi-diameter and the Sun-Moon elongation. A wider crescent is brighter and easier to see with the naked eye. Very thin crescents (below ~0.3 arcminutes) are extremely difficult to detect.
Based on analysis of our historical sighting data, we identified minimum threshold values for each parameter. When a parameter exceeds its threshold, conditions for that factor are considered favorable. The more thresholds met, the better the overall visibility prospects.
| Parameter | Threshold |
|---|---|
| Moonset Lag | ≥ 45 min |
| Moon Age | ≥ 21 hrs |
| Moon Altitude | ≥ 8° |
| Elongation | ≥ 10° |
| Illumination | ≥ 0.9% |
| ARCV | ≥ 10° |
| Crescent Width | ≥ 0.3′ |
Beyond simple threshold checks, we use a Random Forest machine learning model (200 decision trees) to produce a nuanced confidence percentage. The model considers all seven astronomical parameters plus the count of thresholds met simultaneously, capturing complex non-linear interactions between factors that a simple threshold check would miss.
2,000+
Balanced Training Records
9
Input Features
200
Decision Trees
The model outputs a probability (0–100%) which is mapped to a human-readable confidence label:
Verified moon sighting observations collected by CrescentWatch.org, spanning from 2005 to 2023. Each record includes the date, location, sighting result (visible or not), and the computed astronomical parameters at the time of observation.
Additional verified observation records sourced from MoonSighting.org.uk, providing sighting reports from the UK and international locations that strengthen and diversify our training dataset.
Astronomical calculations use NASA's Jet Propulsion Laboratory DE421 ephemeris file, which provides highly precise positions of the Sun, Moon, and planets. Computations are performed via the Skyfield Python library for accurate rise/set times and angular positions.