About this tool
Get accurate daily prayer times and the Qibla bearing for any city, computed offline on your own device.
The Prayer Times & Qibla Direction computes the five daily prayer times and the Qibla bearing from the standard solar equations — Julian date, solar declination, the equation of time and hour angles — entirely on your device, with no lookup or network request. Choose from 92 built-in cities or use your browser location, pick a calculation method (Muslim World League, ISNA, Umm al-Qura or Karachi) and the Shafi or Hanafi rule for Asr, and it returns Fajr, Dhuhr, Asr, Maghrib and Isha plus sunrise and Islamic midnight. The Qibla is the great-circle bearing to the Kaaba at 21.4225°N, 39.8262°E, given in degrees from true north alongside the distance in kilometres.
Open Prayer Times & Qibla Direction on AltFTool — it loads instantly in your browser.
Use 'Search cities' to pick one of the 92 built-in cities or press 'Use my location', then set the Date.
Open Calculation settings to choose the convention — Muslim World League, ISNA, Umm al-Qura or Karachi — the Shafi or Hanafi Asr rule, and a high-latitude rule if Isha comes out undefined.
Read Fajr, Dhuhr, Asr, Maghrib and Isha with the next prayer called out, and the Qibla bearing in degrees from true north with the distance to the Kaaba, then press Copy times.
MWL uses Fajr 18° and Isha 17°, ISNA 15°/15°, Karachi 18°/18°, and Umm al-Qura Fajr 18.5° with Isha fixed at 90 minutes after Maghrib — the parameters are on screen, not hidden.
Angle-based, one-seventh and middle-of-the-night rules are all available for locations where the sun never reaches the twilight angle, and the page flags when an adjustment has been applied.
The bearing is computed from true north via the great-circle formula and shown with the distance to Mecca, plus a reminder that a phone compass usually reads magnetic north and needs the local declination added.
Because different organisations use different twilight angles for Fajr and Isha. This tool exposes four: MWL at 18°/17°, ISNA at 15°/15°, Karachi at 18°/18°, and Umm al-Qura at 18.5° with Isha 90 minutes after Maghrib (120 minutes in Ramadan). Pick the one your local mosque follows and the times will line up.
Asr is set by shadow length: the Shafi (and Maliki, Hanbali) rule starts Asr when an object's shadow equals its own length plus its noon shadow, while the Hanafi rule uses twice the object's length. The Hanafi setting therefore gives a noticeably later Asr.
As the initial great-circle bearing from your coordinates to the Kaaba at 21.4225°N, 39.8262°E, expressed in degrees clockwise from true north. Note that a magnetic compass points to magnetic north, which differs from true north by anywhere from under a degree in much of India to more than 15° in parts of North America — add your local declination before using the figure on a compass.
They are astronomical calculations and should agree closely with published timetables using the same method, but conventions differ on small details — this tool adds one minute to solar noon for Dhuhr and uses the 0.833° refraction figure for sunrise and sunset. Where a local mosque or religious authority publishes a timetable, follow that; treat these figures as a reference, especially at high latitudes where the rules are approximations.