Categories We Write About

Schedule backups of browser bookmarks

Scheduling backups of browser bookmarks is essential for ensuring that your important links and saved pages are never lost due to crashes, syncing errors, or accidental deletions. Here’s how you can automate bookmark backups for the most popular browsers:


1. Google Chrome (Windows/macOS/Linux)

Manual Bookmark File Location

  • Windows:
    C:Users<Your-Username>AppDataLocalGoogleChromeUser DataDefaultBookmarks

  • macOS:
    ~/Library/Application Support/Google/Chrome/Default/Bookmarks

  • Linux:
    ~/.config/google-chrome/Default/Bookmarks

Automated Backup (Using Script + Task Scheduler/Cron)

Windows:

  1. Create a Batch Script (e.g., backup_chrome_bookmarks.bat)

    bat
    @echo off setlocal set timestamp=%DATE:~10,4%-%DATE:~4,2%-%DATE:~7,2%_%TIME:~0,2%%TIME:~3,2% set timestamp=%timestamp: =0% xcopy "%USERPROFILE%AppDataLocalGoogleChromeUser DataDefaultBookmarks" "%USERPROFILE%DocumentsBookmarkBackupsBookmarks_%timestamp%.bak" /Y endlocal
  2. Schedule It

    • Open Task Scheduler → Create Task

    • Trigger: Daily/Weekly

    • Action: Start a program → Point to the .bat file

macOS/Linux:

  1. Create a Shell Script (e.g., backup_chrome.sh)

    bash
    #!/bin/bash TIMESTAMP=$(date +"%Y-%m-%d_%H-%M-%S") cp "$HOME/Library/Application Support/Google/Chrome/Default/Bookmarks" "$HOME/Documents/BookmarkBackups/Bookmarks_$TIMESTAMP.bak"

    (Linux path: ~/.config/google-chrome/Default/Bookmarks)

  2. Automate with Cron

    • Open terminal: crontab -e

    • Add line for daily backup (at 6 PM):

      bash
      0 18 * * * /path/to/backup_chrome.sh

2. Mozilla Firefox (All Platforms)

Using Built-in Backup Feature (JSON or HTML)

Firefox automatically saves daily backups:

  • Location:
    Profiles/<random>.default-release/bookmarkbackups/

You can also trigger a manual or scripted export.

Automated Script (HTML Export via places.sqlite or Profile Sync)

Using Firefox CLI Add-on or Sync

Due to lack of CLI support, automate copying the profile folder.

bash
#!/bin/bash TIMESTAMP=$(date +"%Y-%m-%d_%H-%M-%S") cp -r "$HOME/.mozilla/firefox/*.default-release/bookmarkbackups" "$HOME/Documents/BookmarkBackups/firefox_backups_$TIMESTAMP"

Schedule via cron as described above.


3. Microsoft Edge

Edge stores bookmarks similarly to Chrome:

Bookmark File Location

  • Windows:
    C:Users<Your-Username>AppDataLocalMicrosoftEdgeUser DataDefaultBookmarks

Backup Script

Same as Chrome, change the path accordingly in your .bat script.


4. Safari (macOS)

Safari bookmarks are stored in:

  • ~/Library/Safari/Bookmarks.plist

Automated Script for Safari

bash
#!/bin/bash TIMESTAMP=$(date +"%Y-%m-%d_%H-%M-%S") cp "$HOME/Library/Safari/Bookmarks.plist" "$HOME/Documents/BookmarkBackups/SafariBookmarks_$TIMESTAMP.plist"

Add to crontab for scheduling.


Best Practices for Bookmark Backup Scheduling

  • Use Cloud Sync as a First Layer: All major browsers support syncing bookmarks with a user account.

  • Local Backup as a Second Layer: This guards against sync failures or account-related issues.

  • Offsite Backup (Optional): Sync the backup folder to Google Drive, Dropbox, or an external drive.

  • Retention Policy: Clean backups older than 30 days using an additional script.

Bonus: Clean Old Backups Script (Bash)

bash
find ~/Documents/BookmarkBackups/ -type f -mtime +30 -name "*.bak" -exec rm {} ;

Schedule it weekly to avoid disk bloat.


Conclusion

Automating browser bookmark backups ensures you’re always protected against data loss with minimal effort. Whether using Windows Task Scheduler or cron jobs on Unix systems, you can create a robust, self-maintaining bookmark archive in just a few steps.

Share This Page:

Enter your email below to join The Palos Publishing Company Email List

We respect your email privacy

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Categories We Write About