I want to know where exactly are stored the apn's that are added by the user on Android. I want to edit them manually using X-plore(or any other root file explorer).

I know that in /system/etc/apns-conf.xml are stored the APN that come preset with the device, but I'm looking for the XML file where the user added APN are stored instead.

  • For anyone else arriving here to find out how Android automatically picks up APNs, the APN preset configurations are now found in /etc/apns-conf.xml, and are linked to a SIM that is inserted by the mmc and mnc. – Bilko Apr 16 '19 at 23:58
  • @Bilko /etc is a symlink to /system/etc. Both files are same. – Irfan Latif Oct 25 '19 at 15:19

I think it depends on your ROM .I recently checked mine and are in the following folder:

/data/data/com.android.providers.telephony/databases/.(telephony.db). You can try opening this .db file as text with a suitable file explorer and see if you can find them. (These are apns in the ROM by default)


I created a test apn manually and did a search, I learnt that its actually stored here: /data/data/com.android.settings/shared_prefs/com.android.settings_preferences.x­ml

(This xml also contains a lot of information found in settings but if you use a keyword search to try and find your manual apn, it will be much faster)

Some of the carrier apns happen to be auomatically added when you insert a new sim card, corresponding to the country, that is why they are stored in telephony database,I reckon. I hardly enter these apns manually even when I change a SIM card.

  • 1
    +1 On Android 9 manually added APNs are only added to telephony.db, com.android.settings_preferences.x­ml doesn't exist. – Irfan Latif Oct 25 '19 at 15:21

When looking at a Pixel 3a device running Android 10 the location is data/user_de/0/com.android.providers.telephony/databases/telephony.db user_de is the _d_evice _e_ncryption related user directory, use user instead if the phone does not support this

Not strictly related to the question about the user provided storage location, but this might be useful for people landing here after a search:

When looking in TelephonyProvider there are 4 different locations with increasing precedence:

  • Default APNs: /system/etc/apns-conf.xml
  • OEM APNs: /oem/telephony/apns-conf.xml
  • OTA Update APNs: /data/misc/apns/apns-conf.xml
  • Product APNs: /product/etc/apns-conf.xml

Note: In Android 10 the system partition cannot be mounted read-write. Use a Magisk module to change the APNs or update the APN under /data/misc/apns/apns-conf.xml. This path is writable after an su.

The APNs are finally stored in database /data/user_de/0/com.android.providers.telephony/databases/telephony.db. Like mentioned above be flexible here about the user_de part.

Also take note that an ApnSourceService method was introduced in Android 10(?). This is a vendor specific implementation to lookup APNs. This is a not documented service. If this service is active all the XMLs will be ignored. Use a Magisk module to turn off this service if needed.

  • /data/user_de is correct, it's the Device Encrypted storage on devices with FBE support. Many configurations have moved from /data/user (/data/data) to this encrypted path. – Irfan Latif Dec 10 '19 at 21:04
  • Thanks. I have improved the answer here. – k_o_ Dec 11 '19 at 23:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.