One link that opens the right maps app, on any device.
There is no standard for opening a map location natively. Android uses geo: intents, iOS and macOS intercept Apple Maps links, while on desktop Google Maps in the browser is the go-to. Pick one format and every other platform breaks.
Building differentiation into each project adds complexity — often a plain link is all you need.
One URL that handles detection. Add ?q= with a place, coordinates, or a query — done.
https://maps.rbt.no/?q=Hornindalsvatnet
| Platform | Redirects to |
|---|---|
| Android | Native maps app via geo: intent |
| iOS / macOS / iPadOS | Apple Maps |
| Windows / Linux | Google Maps (web) |
| In-app browsers | Tries native, falls back to Google Maps |
https://maps.rbt.no/?q=Hornindalsvatnet
https://maps.rbt.no/?q=59.9139,10.7522
https://maps.rbt.no/?q=pizza+oslo
The visitor's platform is detected client-side via user agent. The page immediately redirects to the appropriate maps URL using location.replace() — no history entry is pushed, so the back button returns to the previous page.
For in-app browsers (Facebook, Instagram, TikTok, etc.) and Android without a maps app installed, a 2-second fallback redirects to Google Maps web.
iPadOS 13+ reports as "Macintosh" in the user agent string and lands in the macOS branch — correct, since Apple Maps is the target for both.
No cookies. No data stored. IP addresses are processed for the HTTP connection but not logged. Visitor stats are anonymized.
Deployed to GitHub Pages via GitHub Actions. Custom domain configured via CNAME.