How can I backup Realm db on my machine?

Hi,

I got a React native (0.63) project and I’m using realm nosync.
I’m trying to create a copy of my db and save it in my project folder.

using Realm.acopyBundledRealmFiles('../realmdb/') throw a permission error
using ~/workspace/realmdb/ throw an error sayign folder not exsit.

At this point, I’m not sure if it’s trying to save it to the actual device or my machine :confused: either way I’m stuck.

Thanks for the help.

Hi. Realm.db file is stored inside of the application bundle.

If you would like to copy it from your phone to the desktop please follow the steps described here. https://support.realm.io/support/solutions/articles/36000064525-how-do-i-locate-realm-files-on-a-device-or-simulator-

If you would like to open realm file on desktop, please use Realm Studio https://docs.realm.io/sync/realm-studio

1 Like