Issues And Solutions To MacOS Notes App
Aug 13, 2023

Not so long ago I wanted to backup some things from the Notes App on a Mac. I found thorugh some googling that the easiest way was to just back up the following files:

  • NoteStore.sqlite
  • NoteStore.sqlite-shm
  • NoteStore.sqlite-wal

Once you have those, you can simply drop them into the same location later and access your notes. Fastforward ten months and remember I have backups of those files on a USB drive and could use some of the snippets off of them for reference. Should be easy enough, just load them onto a local mac and be good right? Nope. The Notes App would crash after about three seconds and revert to fresh settings.

Next step was trying in a Virtual Box. Spent the time getting it running, which wasn't very long considering I didn't have to really babysit it. Transfered the files to the correct location on the VM and nope. Same issue came up.

Now I'm at a loss. I start looking through things and switch over to my WSL Ubuntu install, ap-get install sqlite3 and try at it that way since, according to most sources, they were stored as just a flatfile sql database. Well that ended up as a headache for about ten minutes and I couldn't get anything useful out of it.

At this point I just knew someone had to have ran into this before and should have some type of parsing or tool for this.

After searching a bit more I came across this python repo: Apple Notes Export Tools

Supposedly this could convert the NoteStore.sqlite to seperate html files for each note. After some modification to the script in regards to the location of the sql file, it actually worked! 🎉

Now I can go through, find the one snippet I needed... three days later. Hope this helps someone else from getting stuck in the same situation.