How to save configuration of Syncthing


I have set up Syncthing between 2 Linux Mint PC, a Windows Netbook and 2 Andriod phones… everything is working fine except for a few minor issues ( which I see others have mentioned so I am tracking their progress)

As a result, I have just bitten the bullet and un-subscribed from DripBox.

My question… how do I save the configuration on each Syncthing device so that I can re-install if/when needed?

Thanks, Tony

You need to backup these files:

You should only backup the index-*.db directory, if you can make sure that the the synced files will be the same after restore. Otherwise you will for sure get conflicts.

1 Like

Or worse, syncthing will assume the files are gone (deleted) and propagate the deletes to everyone.

1 Like

In other words, backup .config/syncthing and ignore index-*.db – is that correct?

I’m not sure why I would ever want to backup index-*.db files, except to perhaps save rescanning and bandwidth to other nodes?

1 Like

Thats the reason, yes. Initial scanning can take very very long.

So that raises an interesting question: if my total config directory is ~350Mb, is Syncthing going to exchange that much data with other nodes to “recreate” the index?

I’m not sure, but I have set

My Device -> Advanced -> Compresson -> Metadata Only

Dunno, how much this saves, but one of my config directories is about 14GB, I doubt, it’s all transfered :slight_smile:

The database is many things, only part of it is what is exchanged.

1 Like

Hi, I don’t recall changing the default config on install but I am finding the config in this folder


with contents of

cert.pem config.xml csrftokens.txt https-cert.pem https-key.pem index-v0.14.0.db key.pem

Does this look correct?

This is the location gtk wrapper uses, plain syncthing uses a different location.


You’re particularly interested in the files cert.pem, config.xml, key.pem. These files are crucial. You may however back up the entire directory, just in case (possible changes to the files inside directory in the future, etc).

Just be aware that files named like <number>.ldb (inside a index-*.db folder) contain the database. The database can be rebuild without much trouble and restoring the database from a backup can cause errors, so it might be best to not restore it after a re-install.

I think most everyone is aware, but just in case someone doesn’t realize:

While its good to backup the config files, its crucial to keep them secret. Don’t store them in an insecure location.

Access to those files will allow someone to retrieve/read all files and traffic from other devices for that configuration.


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.