Qibla direction from your location
Allow your location and your phone’s compass, and we show the direction of the Kaaba in degrees and with a live arrow.
Open this page on your phone
The Qibla compass works on phones only, because it reads the direction sensor in the device. Open this page on your phone to find the Qibla.
Approximate: it depends on your phone’s compass. Confirm it with a mosque or a trusted compass.
City names: GeoNames (CC BY 4.0)
How the compass works
We calculate the angle between true north and the Kaaba (21.4225° N, 39.8262° E) along the shortest path over the Earth, using the open-source adhan library. A phone compass points to magnetic north, so we correct it with NOAA’s World Magnetic Model (WMM2025). The value is measured clockwise from north. On a phone we read the direction sensor and turn the dial so the arrow points up when you face the Qibla.
Note: phone compasses are affected by metal, magnets and nearby devices. Move the phone in a figure 8 and keep away from metal surfaces.
Frequently asked questions
How do I find the Qibla from my location?
Allow location and the direction sensor, and we calculate the angle between north and the Kaaba along the shortest path over the globe. Turn your phone until the gold arrow points up.
Is the Qibla compass accurate?
The calculation is accurate, but a phone compass is affected by metal and magnets. Move the phone in a figure 8 to calibrate, and keep away from electronics. If in doubt, ask at the nearest mosque.
Do you store my location?
No. The calculation happens entirely in your browser, and your location is not sent to any server.
Why is the angle different from a straight line on a flat map?
The Earth is round, and the shortest path between two points is a great-circle arc. That is what we calculate.
What if the compass does not work on my device?
We do not show a direction without a compass, so you never see a wrong reading. Try Chrome or Safari on a phone, and check that Motion & Orientation access is on in your settings.