Search code examples
androidrealmrooted-device

Can a non-rooted phone android user see/edit the data stored in Realm DB?


I am storing my data in Realm DB, I wanted to know is it possible for a non-rooted phone user to see/edit this data or not ??

I am asking this as a security point of concern because when using Shared pref/SQLite on a non-rooted phone no one can see/edit the data.


Solution

  • If the user will be able to view the database depends on where you have saved the database. If you are not modifying the location of the database, then by default the realm database is stored at the same location as SQLite db. So, the user should not be able to view the file.

    However, if you are placing the database in a custom folder accessible without root (like sdcard) the user will be able to view it.

    For the safety purpose, you can encrypt the database. You can read more about it here