為了改善您的使用體驗,本網站正在進行維護,部分功能暫時無法使用。若本站的文件無法解決您的問題,想要向社群發問的話,請到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 發問,我們的社群成員將很快會回覆您的疑問。

搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

了解更多

Firefox wiped my saved logins - How to restore/merge from backup?

  • 3 回覆
  • 1 有這個問題
  • 36 次檢視
  • 最近回覆由 cor-el

more options

I have firefox sync set up, but I ask it not to sync logins. Recently, one of my profiles had an issue with sync and it asked me to reconnect. After reconnecting it cleared all my saved logins. I have a backup of `logins.json` but how can i restore it so i have the old and new logins?

Thanks, Jayen

I have firefox sync set up, but I ask it not to sync logins. Recently, one of my profiles had an issue with sync and it asked me to reconnect. After reconnecting it cleared all my saved logins. I have a backup of `logins.json` but how can i restore it so i have the old and new logins? Thanks, Jayen

所有回覆 (3)

more options

Restoring logins.json (and possibly the matching key4.db) will replace all currently saved passwords. It is not possible to merge passwords other then via Sync AFAIK. Best is probably not to use the same device name when you (re)connect to Sync to prevent losing your current personal data. When you use the same device name then Firefox may think you want to replace (initialize) your current personal data with data previously stored on the Sync server. If you use a different name then Firefox may want to merge instead of replacing your personal data. You would have to test this.

more options

Thanks for your help. Can I use the matching key4.db to merge? I assume if firefox can do it, so can I. I would prefer not to send the passwords to firefox sync if possible. Although if I know only I have the [private] key then maybe it's ok.

Now that I think about this more, I think it happened in the reverse order. login.json got corrupt first, then sync broke [since it didn't have the login information].

I have backed up the new login.json and restored the old login.json and it seems to be fine. There aren't too many in the new one, so I've re-entered them manually.

more options

The passwords are always stored in logins.json. The key4.db file and previously key3.db file stores the basic encryption key and the master password. The logins.json and key4.db files need to match to be able to decrypt the login data.