Google Takeoutâ„¢ and similar backup solutions are great. But can you make the static files more useful? Here’s how you can turn them into a self-hosted archive that can be accessed in similar ways to the real thing.
Whatever you do, make sure it’s secure.
Dovecot supports many storage formats. You can setup a simple Dovecot IMAP server by following for example the quick configuration instructions here. One advantage of doing this is that you get server-side search, and can read your archived emails from your phone.
Contacts & calendar
Google exports data in vCard format aimed at Apple devices, which has some side effects, see e.g. https://alessandrorossini.org/the-sad-story-of-the-vcard-format-and-its-lack-of-interoperability/. This may result in data not being viewable in some UIs, which is annoying.
If you can find some software which uses plain vCards as backend (rather than a database), such as perhaps calypso or maybe radicale, then hopefully you can import the backup and serve it with (hopefully) minimal changes (calypso for example does split the 1 vCard file into 1 vCard file per contact, but I’ve not done a thorough diff to confirm it’s 100% lossless).
I discovered that Google’s vCards only contain URLs for PHOTO
s, so if the data is deleted from Google’s servers, then the pictures will disappear, so you may wish to inline them as base64-encoded strings instead. Google Takeout’s vCard export does also export the pictures though.
Closing thoughts
It’s a good idea to test your backups anyway, right?
Google and Google Takeout are a trademarks of Google LLC.