12 hours ago
Google killed Maps Timeline, so I self-hosted a better one
Dhruv Bhutani / Android Authority
As an avid traveler, Google Maps Timeline has long been one of my favorite hidden features. I'm used to opening it on slow Sunday afternoons and wandering through my own travel history. It showed alleyways I had forgotten, long layovers that blurred together while stepping out for a quick brunch across a new city, and impulsive last-minute rail journeys across Eastern Europe that never made it into photos. It's always felt like a private travel diary logging everywhere I've been.
So the announcement that Google will be killing Timeline view as we know it came as a bit of a shock. The online timeline view is no longer accessible, and the only copy lives on your phone — unless you explicitly trigger a cloud backup. As with all things Google, if a feature is too good, it eventually gets killed (even if it's in the name of privacy). For all practical purposes, Google was about to move a decade and a half of my location history behind a Takeout export. In other words, I could download my past travels or watch them vanish. If I cared about those memories, it was clear that I had to figure out a way to take ownership of that data. So I did the obvious: I looked up a self-hosted alternative.
Even at first glance, OwnTracks looked like the right tool. It's open source, it works entirely on personal infrastructure, and it stores data in plain text. The interface is reasonably polished, and there's no hidden monetization. All of which is exactly what I wanted in a Google Maps Timeline replacement.
Setting it up took a weekend of tinkering on my Synology NAS, but the payoff was a location log that lives on hardware I've already paid for. I can choose what to do with that data, including integrating it with Home Assistant, and I can back it up wherever and as often as I like. Win-win.
Setting up OwnTracks and importing my old Maps data
Dhruv Bhutani / Android Authority
Getting started with OwnTracks is an involved process, so I began with the basics. It needs an MQTT broker to shuttle messages between the phone app and the server. I installed Eclipse Mosquitto in a Docker container. The documentation is clear enough about ports and volume mounts. Once the broker was running, I pointed the OwnTracks app on my Pixel 9 Pro to the NAS's LAN IP and watched as JSON packets began appearing in the logs. While I'm fine with syncing my location history whenever I'm back home, you can also set up a reverse proxy and update your location in real time. Perhaps a project for another time.
The second step was storage and playback. OwnTracks is split into two parts: the recorder, which, well, records your location, and the frontend, which displays it. The recorder connects to the MQTT broker we installed earlier, writes every update to disk, and exposes an HTTP API. Installing it was straightforward with Docker Compose, and you can also use Synology's Container Manager for an even easier setup. By default, the recorder serves a basic map on port 8083. It's not flashy, but it works. I saw my evening walk pop up almost in real time. And if you're just looking to log your location from here on out, you can skip the frontend altogether. If importing your Timeline history is important to you, like it was to me, you'll want to continue installing the frontend. The process is similar to installing the recorder and shouldn't take over an hour.
Installing OwnTracks wasn't frictionless, but once it worked, it felt like stepping back into Google's old timeline view. Except this time, everything was self-hosted.
Paired with the OwnTracks app on Android or iOS, the system also works offline. If the internet drops or you haven't set up external access, the data still lands on your NAS or home server as soon as your phone reconnects to the MQTT broker.
It has to be said that Google does not make it easy to import your old location data. After running the export through Google Takeout, importing my old data took quite a bit of wrangling. Takeout handed me a folder of JSON files, and it took a community script to convert those into the format the recorder expects. Once that was done, I piped in a decade's worth of travels over to OwnTracks, restarted the service, and watched as it quietly added everything into the database. It wasn't frictionless, but once it worked, it felt like stepping back into Google's old timeline view, except this time, everything was self-hosted.
Taking ownership of your personal data
Dhruv Bhutani / Android Authority
Despite the effort involved in setting up OwnTracks, the end result makes it worth it. The process taught me all the variables that go into getting the service running and reminded me why self-hosting feels liberating. If I ever need to troubleshoot things, it should be fairly trivial, and every fix is more or less final. I can choose to never update the service until a major release. More specifically, Google can't mark my NAS as deprecated. Which, you'd have realised by now, is a feature in itself. Additionally, if I want to tweak something, I can read the source code and add it in.
Coming to the experience of using OwnTracks, it, predictably, isn't as full-featured as a product by Google. All you get is a map with location markers showing where you've been. Since the service leverages OpenStreetMaps, the data isn't as full-featured either. So, this might not be your best bet if you're trying to pinpoint an old restaurant you visited a decade ago, or expect add-ons like Street View to walk back in your own steps.
Self-hosting gives me a private and more permanent solution for my location history timeline, and it's totally under my control.
But for all its limitations, OwnTracks does a great job of helping you visualize where you were at a specific point in time. Depending on your needs, that might be enough. While OwnTracks doesn't offer heatmaps or trip labels, it does offer something more important: permanence. The data sits in JSON files, neatly organized by year and month. Any mapping library can read it. If I want a heatmap, I can generate one with Python in five minutes. There's a lot of flexibility here.
Of course, privacy is the other most obvious win. Nothing leaves my network unless I push it. The recorder supports end-to-end encryption with a pre-shared key, so even if I sync data between sites, the raw coordinates stay protected. No analytics. No third-party servers unless I choose to use them. Since the service is fairly lightweight, hardware requirements have also been modest. You could run this on a spare Raspberry Pi if you choose to. MQTT and the recorder together use less than one percent CPU on a five-year-old NAS. The frontend is just Nginx serving static files. A full year of movement data, logged at ten-second intervals, weighs in at just a few hundred megabytes. That's a very tiny footprint, all things considered. I've also layered on additional conveniences for more peace of mind. For example, the location data gets backed up nightly not just to a second NAS, but also to — ironically — Google Drive.
Is this for everyone?
Dhruv Bhutani / Android Authority
Could a less technically inclined friend replicate this? Probably, if they're comfortable using Docker Compose and a terminal. OwnTracks is not plug-and-play, but community write-ups help fill in the gaps. There are guides for Synology, Unraid, Raspberry Pi, and plain Linux. And the tooling improves each year. But I'd be kidding if I said it was easy. In an ideal world, we shouldn't have to run a service like this. But with Google's ham-fisted approach toward beloved services, it's probably for the best.
If Google brings back the old Timeline tomorrow, I'd still stick with OwnTracks for its permanence.
I'm not claiming OwnTracks is perfect. The mobile app occasionally stops publishing when Android's battery manager gets too aggressive. The map viewer lacks search. Importing large datasets can freeze the UI until processing completes. But these are tradeoffs I can live with. They're also not serious enough to impede usage. All that said, location history feels trivial until you lose it. Sometimes, the only record of a detour or a missed turn that led you to a cool spot is a dot on a map. That dot can jog a memory or simply remind you that you covered a lot of ground that year. Now that dot lives permanently on my NAS. If Google brings back Timeline tomorrow, I'd still stick with OwnTracks because of that permanence.