Skip to content

File History, backups and differences

Each time a note is saved, mdai keeps a version of it — at most one every 5 minutes, kept for up to 7 days. All history together is capped at 50 MB; past that, the oldest versions are removed first. When you rename a note, its history moves with it.

Type history in the command palette (⇧⌘P / Ctrl+Shift+P) and choose File History. The versions of the note you are in are listed newest first, by date and time. Click one to read it.

To go back to it, click Restore This Version, then click again — the button asks “Click again to replace the file with this version”. The file on disk is replaced with that version and the editor shows it.

Restoring can itself be undone: the text the file had just before is still in the list, and you can restore it the same way.

The versions are kept in mdai’s own folder on your computer, not in your vault, so they do not show up among your notes.

Type backup in the command palette and choose Encrypted Vault Backup….

  1. Type a password twice.
  2. Click Save backup… and choose where to save it. mdai suggests the name of the vault and today’s date, such as my-vault-2026-09-30.zip.

The whole vault goes into one .zip file, and each file in it is encrypted with AES-256. When it is done, mdai tells you how many files went in.

  • To open the backup you need the password and an app that supports AES, such as 7-Zip or Keka. The Archive Utility built into macOS cannot open it.
  • The names of the files inside the zip are not encrypted — only their contents are.

If a note changes on disk — another app, a sync service — while you have unsaved edits in mdai, two things appear:

  • A dialog, File changed outside the app, with Load from disk (take the version on disk; your unsaved edits are dropped) and Keep my version.
  • A message, Save failed, with Save as… and Show difference.

Show difference shows the two versions line by line: red lines are only on disk, green lines are only in the editor. Look first, then choose in the dialog.

At any time, type diff in the command palette and choose Diff With File on Disk. It shows what you have changed in the note since you opened its tab: green was added in the editor, red was removed.