This Week's Sponsor:

FastMinder

A Simple, Lightweight, and Clutter-Free Intermittent Fasting Tracking Experience


Open Google Maps Directions With Siri or Launch Center Pro

Here’s a fun experiment to launch the Google Maps app via URL scheme directly into a new Directions view.

As I detailed this morning, the new Google Maps app for iPhone lets you launch specific views and modes using a URL scheme. You don’t need to be a developer to use the URL scheme; this means you’ll be able to launch the Google Maps app from Safari, Launch Center Pro, or any other launcher using the base comgooglemaps:// URL.

Google’s URL has a scheme for directions with addresses and transportation parameters. It lets you specific a starting address with the saddr parameter, and a destination address with daddr.

Further, you can instruct the URL to open a specific directionsmode, such as driving or transit.

With these parameters, it becomes possible to set up a nice automated workflow to launch directions using Siri or Launch Center Pro.

In Siri, you can’t launch arbitrary URL schemes, but you can trick the assistant into displaying them. Specifically, you can assign URLs to contacts and display their contact card, showing a tappable URL. AS an example. I’ve put together a Google Maps URL that takes me from my current location to Piazza Giuseppe Verdi here in Viterbo. There is no parameter for “current location”, but Google Maps is smart enough to recognize a blank saddr value as “where I am right now”. For the destination address, Google says we can use “latitude,longitude or a query formatted address”, so for the sake of the experiment I’ll use the simplest way: copying the query version from Google Maps’ website.

On Google Maps’ website, search for a location, then copy its link using the Link button on the left. The address for Piazza Giuseppe Verdi in Viterbo will look like this. We want to use the human-readable portion of the query, Piazza+Giuseppe+Verdi,+Viterbo,+Italy. We’ll use this to compose the final URL.

For Google Maps, I want a URL that launches the app in directions mode, with driving directions, satellite view, and standard mode (not Google Street View). By using the standard parameters documented by Google and the portion of the link copied from the Maps website, the URL will be:

comgooglemaps://?saddr=&daddr=Piazza+Giuseppe+Verdi,+Viterbo+Italy&directionsmode=driving&views=satellite&mapmode=standard

At this point, we can assign this URL to a Contacts card. To do so, open Contacts on your iPhone, find a contact (or create a new one), hit Edit, and assign the URL to a URL field, such as “home page”. While you may find my Piazza Giuseppe Verdi useless, think about doing this for your Home address: you’ll get instant driving directions with Google Maps for your house every time. I called my contact “Federico Home”.

Once assigned, Siri will see it. In Siri, say something like “Show Federico Home”, and you’ll be given the contact card you’re looking for, with a Google Maps URL you can tap on to open the app with the driving directions from your current location to the preset destination already filled in. You’ll just have to choose a route, and navigation will start.

With the same concept, Launch Center Pro users can create an action to specify a destination address every single time. Simply replace the destination address with [prompt], which will open Launch Center Pro’s keyboard prompt. From there, write your destination address normally, and Launch Center Pro will take care of properly encoding the query when passed with the URL scheme.

Until Launch Center Pro officially supports a Google Maps action, you can use this method to quickly set a destination address. The best part is that the URL scheme is really flexible, so you can set up custom actions for Street View, zoom modes, and so forth. For more information on the Google Maps URL scheme, check this page.

Unlock More with Club MacStories

Founded in 2015, Club MacStories has delivered exclusive content every week for over six years.

In that time, members have enjoyed nearly 400 weekly and monthly newsletters packed with more of your favorite MacStories writing as well as Club-only podcasts, eBooks, discounts on apps, icons, and services. Join today, and you’ll get everything new that we publish every week, plus access to our entire archive of back issues and downloadable perks.

The Club expanded in 2021 with Club MacStories+ and Club Premier. Club MacStories+ members enjoy even more exclusive stories, a vibrant Discord community, a rotating roster of app discounts, and more. And, with Club Premier, you get everything we offer at every Club level plus an extended, ad-free version of our podcast AppStories that is delivered early each week in high-bitrate audio.

Choose the Club plan that’s right for you:

  • Club MacStories: Weekly and monthly newsletters via email and the web that are brimming with app collections, tips, automation workflows, longform writing, a Club-only podcast, periodic giveaways, and more;
  • Club MacStories+: Everything that Club MacStories offers, plus exclusive content like Federico’s Automation Academy and John’s Macintosh Desktop Experience, a powerful web app for searching and exploring over 6 years of content and creating custom RSS feeds of Club content, an active Discord community, and a rotating collection of discounts, and more;
  • Club Premier: Everything in from our other plans and AppStories+, an extended version of our flagship podcast that’s delivered early, ad-free, and in high-bitrate audio.