Log every drive automatically with your iPhone
No Tesla needed, no app to install. Your iPhone's built-in Shortcuts app tells MileHatch when you get in the car and when you get out. MileHatch works out the miles and puts the trip in Needs review. You just tap Business or Personal.
Takes about 5 minutes, once. Do it on your iPhone (open this page there: milehatch.app/phone).
- Copy your personal links
After you sign in, open milehatch.app/phone on your iPhone. It shows your two personal links (Start and End) with Copy buttons.
- Make the “MileHatch Start” shortcut
- Open the Shortcuts app and tap + (top right).
- Tap the name at the top and call it MileHatch Start.
- Tap Search Actions, type Get Current Location and tap it.
- Search again for Get Contents of URL and tap it.
- Tap the blue URL and paste your Start link.
- Tap the › arrow on that action to show more. Set Method to POST and Request Body to JSON.
- Tap Add new field → Text. For the key type where. For the value, tap Current Location in the bar above the keyboard.
- Tap Done.
It should look like this:
Get Current LocationGet contents of …/startMethodPOSTRequest BodyJSONwhereCurrent Location - Make the “MileHatch End” shortcut
- In Shortcuts, press and hold MileHatch Start → Duplicate.
- Open the copy, rename it MileHatch End.
- Tap the URL and replace it with your End link.
- Below it, search for Get Dictionary Value and tap it. Set it to get the Value for key review_url in Contents of URL.
- Search for If and tap it. Set it to If Dictionary Value has any value.
- Drag Open URLs (search for it) inside the If, above Otherwise, and set it to Dictionary Value. Tap Done.
After a drive that needs a decision, this opens Review drives so you can tap Log for work or Ignore. Skip the last three steps if you'd rather review later.
- Allow and test (important)
- Tap MileHatch Start once. When asked, choose Allow / Always Allow for your location and for connecting to mcp.milehatch.app.
- Tap MileHatch End once and allow it too.
- Reload this page. The box at the top should turn green and say the signals work.
Automations can't ask for permission, so this test run is what lets them work later. Also check Settings → Privacy & Security → Location Services → Shortcuts is set to While Using with Precise Location on.
- Make it automatic
- In Shortcuts, open the Automation tab and tap +.
- Choose CarPlay if your car has it (otherwise Bluetooth and pick your car).
- Choose Is Connected and Run Immediately, then tap Next and pick MileHatch Start.
- Tap + again: same trigger, but Is Disconnected, and pick MileHatch End.
- Optional: open each automation and turn off Notify When Run.
When CarPlay connectsRunMileHatch StartRun ImmediatelyOnWhen CarPlay disconnectsRunMileHatch EndRun ImmediatelyOn
That's it
Drive as usual. Each trip shows up in Trips → Needs review with the start and end address and the driving distance. Tip: add your home and office in Places and MileHatch can mark regular trips for you.
How accurate are the miles?
MileHatch uses the driving distance of the fastest route between where you got in and where you got out. If you made stops or took a detour, fix the miles on the trip before you mark it Business. Tesla drivers get exact odometer miles instead (connect a Tesla).
Nothing shows up after a drive
- Reload this page: the box at the top shows the last signal and what happened.
- “Without a location”: in the shortcut, Method must be POST, Request Body JSON, and the where field must be Current Location.
- No signal at all: open the automation and make sure it's on and set to Run Immediately, and run each shortcut once by hand to allow it.
- Very short hops (under 0.3 mi and 3 minutes) are ignored on purpose.
- Auto-logging must be on in Places & auto-log.
Privacy
Your iPhone sends its location only twice per drive: when you connect to the car and when you disconnect. Nothing is tracked in between, and no app runs in the background. Your link only lets someone add trips to your log; if you think it leaked, reset it below and paste the new links into both shortcuts.
Android?
Not yet. Android has no built-in equivalent of Shortcuts. You can still log trips by voice with Grok or on the Trips page. Tell us if you'd use an Android app: email us.