"Smart" backup strategy

Is it possible to configure a “smart” backup strategy, ie, keep some of the mid term backup instead of loosing everything after a while? For example, on my Synology, I can have:

  • backup are done every day, we delete old backups after n days, keeping only n latest backup available, BUT…
  • the system ensure to keep m monthly backup AND…
  • and p yearly backup as well.

The algorithm is a bit more complex, but the general idea is here.

I have made a mistakes during configuring the lovelace UI, and did not see it after a while, so I have lost my custom card, because I do not have a 1 month-old backup (and i would be happy to have a 6 months old backup as well).

Approach 1 - Setup a folder on your synology, periodically (1x day) copy your HA config folder in along with the hidden .storage directory. Then use synology to back this up.

Approach 2 - if you are a GitHub user, setup a repo and use this to store your master config. I like this since it allows me to view diffs on what has changed in files and to review changes before deployment.

What I meant really was: why not integrating this feature directly in the hass.io backup mecanism?

Google Drive Backup is an option.

1 Like

I use this Add-On:

And make every night a backup directly to my Synology.
My home Assistant config is synced on Github.

I’ll second the Samba Backup add-on (Supervisor add-on). It works great for exactly what you want and since it’s an add-on it’s mostly part of HA already. I’ve been doing this ever since I discovered that and have had to rely on it a couple of times to get a backup from a couple of days ago.