What to backup to avoid losing my sites?

Since I’ve been using Local, every now and then, either the app or my Mac crashes.

Is not a frequent case (it happens once or twice a year) and I don’t like it, but I can live with that.

The problem is that almost every time this happens, the VM disk gets corrupted and I lose all my work.

The code in on GIT, so that’s not a huge loss, but it’s a massive waste of time setting back all my projects.

First of all, since the local files are not lost, it would help a lot if Local could allow recreating a site based on the local files and maybe a previously made DB backup.

Regardless, it would help knowing what to backup from Local to make sure I can restore my setup when the situation happens again.

I suppose two of the things to backup are the VirtualBox image and the virtual disk, but which additional file (if any) I should backup so I can be back to work in a few clicks?

I usually just exports sites I don’t actively use and store them on my NAS. I’ll import them when I need them again. That makes sure that I don’t have to restore a lot if something goes wrong. You usually work on 3-5 projects at a time… so no need to have 30+ projects in Local.

I figure that will be the case to if you just want to backup… Use the export function (start site, right click, export). If you have 3-5 active projects, that can be done in a matter of minutes.

Other option is to backup the app folder in your Local Sites. This contains the files and the SQL per table.

Also, TimeMachine restores works fine with Local. Just don’t exclude the .docker folder in your home folder.


I think I’ll go through the manual task of exporting them then.

I also work on a few projects at the time. In fact, most of the times is just one project.

It would be nice to automate the exporting anyway. E.g. automatically export projects at a scheduled time.

In my case, I only need it to save time when Local gets corrupted, as I work with code and not contents.

Thanks again.

I seem to remember that at one point automatic periodical site exports were something that was being considered for a Pro version of Local, and I think it would make for a really nice feature to have.

However, it’s been quite a while now since anyone mentioned Local Pro…