Backup Finder sidebar favorites in file

Is there a way to backup my finder sidebar “Favorites” on the left with all my shortcuts to folders on our network drive?
Is this sidebar stored in a file somewhere that I can backup?

Every once in a while the whole sidebar is messed up, so all network folders are gone or the name is just a ? instead of the real folder name.

If there are many folders it takes way too long to restore all of that by hand (and also I can’t remember all those folders until I need it and notice that it’s missing).