Skip to main content

Backup and Restore

WonderPen pays great attention to users' data security, and has built-in comprehensive and reliable backup solutions to reduce the risk of data loss.

WonderPen supports manual backup as well as automatic backup, both of which will back up the complete Library content, including all documents, local pictures, etc.

Automatic Backup

In the Settings window, there is a special Backup panel, where you can set up automatic backups, or manually make an overall backup of the current document library.

In the Backup panel, you can see the backup records of the current document library, and restore to one of the records at any time.

Backup files will be saved in the backup directory in the Library.

The backup file is .zip format. After decompression, there are two ordinary .json files and corresponding attachments (located in the assets folder). If needed, you can use other software or code to parse the .json files to get the complete original data.

By default, WonderPen will automatically back up every 15 minutes, you can set the automatic backup interval in the panel according to your needs.

tip

It is recommended that you always turn on "Auto Backup". When auto backup is turned on, WonderPen will try to make a backup every 15 minutes (or the time you set).

Backup size limitation

Limit maximum size of backups

To prevent the backup folder from being too large, you can set the maximum space for backup files. If the backup exceeds this space, WonderPen will automatically remove the oldest backup.

Smart deleting

Most of the time, the more recent the backups, the more useful they are, and the shorter the time interval, the better. For example, you may want to have access to backups for each hour of the last 24 hours, but for backups from a few weeks ago you can be more cursory and one backup record per day will suffice.

By default, WonderPen will delete the oldest backups in order, but you can also turn on Smart Deleting to let WonderPen delete backups in a smarter way.

The rules for smart deleting backups are as follows:

  • The last 10 backups are always kept (unless the backup space limit is exceeded)
  • For backups in last 24 hours, only keep one per hour
  • For backups in last 30 days, only keep one per day
  • For backups in last 90 days, only keep one per week
  • For backups older than 90 days, only keep one per month
  • If the backup space exceeds the limit, the oldest backup will be deleted

Backup Preview

Click the eye icon in the operation bar of the backup list to quickly view the contents of the backup. Sometimes you may just want to retrieve a certain document from a backup, and don't want to fully restore to that backup, you can use this feature to quickly view the backup.

The interface of backup preview is shown in the following figure:

Backup Preview

Manual Backup and Restore

In the Backup panel in the Settings, there is a Backup Now button, click this button to perform a backup immediately.

In addition to the backup in the backup panel, you can also find the manual backup and restore menu items in the top File menu, as shown in the following figure:

Manual Backup and Restore

Click the Backup Library as... item in the menu to back up the contents of the current Library as a .zip file. You can select where to save the file in the following dialog box.

Click the Restore Library from... item in the menu, and select the backup file (a .zip file) in the pop-up file selection panel (that is, the backup file generated in the above Backup Library as... operation, or the file generated by automatic backup) , you can restore the contents of the current library to the state of the corresponding backup.

tip

There are two manual backup methods:

  1. In the Settings window -> Backup panel, click the Backup Now button.
  2. Click the menu File -> Backup Library as....

The backup files generated by these two backup methods are exactly the same. The only difference is that when using method 1, it will be automatically saved to the backup folder of the current library. When using method 2, you need to manually select the save location of the backup file.

More

All data and attachments of WonderPen are saved in Library, Library is just a normal folder, therefore, in addition to the above backup scheme, You can also directly copy the current Library folder (the folder name usually ends with .wplibrary) to the location you want, and when restoring, overwrite or replace the old Library folder is enough.

In addition to full database backup described in this section, WonderPen also supports Snapshot for documents, you can click to view related docs.