Finding a specific file that stores the names and numbers of your friends and colleagues is a typical task for those who want to do a deep backup or transfer data manually. Unlike photos, which are stored in clear DCIM folders, the phone book database is hidden deep in the system partition.

In standard operating mode, without obtaining superuser rights, you cannot simply go to the file manager and see this file. The Android system isolates application data from each other for security reasons. However, by understanding the file system architecture, you can determine exactly where the contact database is physically located. The location may vary slightly depending on the shell manufacturer and operating system version. For example, on pure contact database.

The location may vary slightly depending on the shell manufacturer and operating system version. For example, on pure Android the directory structure will be the same, but firmware Xiaomi or Samsung may have its own nuances for storing cached data.

Physical location of the database in the system

If you Yes root-rights, you can directly access the system directory where the main database file is stored. It is located on the way /data/data/com.android.providers.contacts/databases/. This is where the file with the name contacts2.db (or similar, depending on the version) is located.

This file is an SQLite database containing tables of numbers, names, email addresses, and call data. Simply copying this file to another phone without the appropriate application structure may not work, since the database is tied to unique application IDs in the system.

⚠️ Attention: Directly editing the file contacts2.db without special knowledge of SQL can lead to complete loss of the phone book. Always create a complete copy before any manipulation.

For ordinary users who do not have superuser rights, this path is closed. Attempts to copy a file through explorers with limited access rights will fail with an access error. In such cases, you need to use the built-in export functions or cloud synchronization.

Why is the file called contacts2.db?

Historically, the first version of the contacts database in Android was called contacts.db. With the release of Android 2.0, the data structure changed, support for multiple accounts and groups appeared, so the file was renamed contacts2.db. This name has been preserved in many modern versions of the system for backward compatibility of structures.

Exporting contacts to VCF format for transfer

The most reliable and universal way to get your hands on a file with contacts is to export to the format VCF (vCard). This format is supported by all smartphones, email clients and computer address books. A file with the extension .vcf contains all text information about the contact in readable form.

To create such a file, you do not need special apps. Just go to the Contacts application, open the menu and select Import/Export. After selecting the “Export to file.vcf” option, the system will prompt you to specify the save location.

  • 📂 Usually the file is saved in the internal memory in the root or in a folder Downloads.
  • 📂 On some devices the path may be /storage/emulated/0/Contacts/.
  • 📂 The file may be called 00001.vcf or contacts.vcf depending on the number of exported records.

The resulting file can be easily sent by email, transferred via Bluetooth or saved to a flash drive. This is ideal for transferring data to an iPhone or other Android smartphone, as the format is an industry standard.

💡

If you export a large number of contacts (more than 500), the system can split them into several VCF files. This is normal and does not indicate an error. Just combine them or import them one by one.

Working with files through a computer and ADB

For advanced users who need to pull out the system database without root access on the phone itself, there is a tool ADB (Android Debug Bridge). By connecting your smartphone to your computer in USB debugging mode, you can run a command to create a backup copy of the contacts application.

The command looks like this and is entered in the computer terminal:

adb backup -f contacts.ab -noapk com.android.providers.contacts

This command will create a file contacts.ab on your computer. However, the file in .ab format is encrypted and compressed. To extract an SQLite database from it, you will need to use special converter utilities, such as Android Backup Extractor.

This method is more complicated than simple export to VCF, but it allows you to save service information, the history of linking contacts to accounts, and metadata that is lost during normal export. This is useful when migrating between devices of the same ecosystem.

📊 How do you usually back up contacts?
Via Google account
Export to VCF file
Third-party applications
Manual rewriting
I don’t make a backup

Synchronization with Google account

In the modern world, the question “where is the file” often loses relevance, since data is stored not locally, but in the cloud. If synchronization with Google Accountis enabled on your device, all your contacts are automatically uploaded to Google servers.

You can access this data through any browser by going to the site contacts.google.com. There you can not only view the numbers, but also export them in CSV format for Excel or VCF for other devices. This is the safest storage method, protecting against data loss if the phone breaks down.

Storage method Access without Root File format Reliability
Local database (SQLite) No .db Low (on reset)
Manual export Yes .vcf Medium (depending on the media)
Google Synchronization Yes (via web) Cloud / CSV High
SIM card Yes Proprietary Low (field limit)

Using the cloud eliminates the need to search for physical files on the device. It is enough to enter the login and password on the new phone, and the entire phone book will be restored automatically within a few minutes.

Features of storage on a SIM card

We must not forget about the old, but still used storage method - on a chip SIM cards. In this case, the files are stored directly in the SIM card memory. This method has serious limitations: usually you can only store the name and number, without the address, photo and additional fields.

The location of this data is not available to the phone's file system as a separate file. Work with them is carried out only through the specialized interface of the “Contacts” application in the “SIM card management” section. Exporting from a SIM card to the phone creates the already mentioned VCF file or records in the local database.

⚠️ Attention: (capacity) SIM cards are limited. Old cards can only hold 250 contacts. Do not store your entire phone book on a SIM card, use it only as an emergency medium.

When you move the SIM card to another phone, contacts will appear automatically if displaying contacts from SIM is selected in the settings of the new device. This is convenient for quick migration, but inconvenient for creating a full backup due to the loss of profile details.

☑️ Checking the integrity of the backup copy

Done: 0 / 4

Restoring data from a backup copy

The process of returning contacts to the device depends on what file you have. If this is a file .vcf, the process is as simple as possible: just click on the file in the file manager, and the system will offer to import the data into the address book.

If you own a database file .db, obtained through root access, the procedure becomes more complicated. You will need to place the file back in the directory /data/data/com.android.providers.contacts/databases/, set the correct permissions and restart the contacts service or the device itself.

Incorrect permissions are a common reason why the phone stops seeing contacts after a manual recovery. The file must belong to the user u0_a... (contacts application identifier), and not root or system.

💡

The most universal and secure format for transferring contacts between any devices is VCF. SQLite database files are tied to a specific version of the system and are difficult to port.

Problems with duplicates and broken files

A frequent problem when working with contact files is the appearance of duplicates. This happens when you import a VCF file on top of an existing synchronized database. The system creates new records instead of updating old ones.

To solve this problem, Android has a built-in “Merge Duplicates” function. She scans the database, finds records with the same names or numbers and offers to merge them into one card. This clears database file of garbage.

Sometimes the export file can become corrupted, especially if the copying process was interrupted. In this case, when you try to import, the system will throw an error. It is recommended to always check the file size: if it weighs 0 KB or several bytes, then the data was not recorded.

Is it possible to edit a contacts file on a computer?

Yes, a VCF file can be opened in Notepad or a text editor, since it is plain text. However, be careful: breaking the tag structure (for example, BEGIN:VCARD) will make the file unreadable for the phone. The .db database file requires specialized software, such as DB Browser for SQLite.

Where are deleted contacts stored?

If you use Google sync, deleted contacts go to the Trash at contacts.google.com and are stored there for 30 days. Locally on a phone without root access, it is almost impossible to recover a deleted database file without special data recovery apps.

Why did the contacts disappear after resetting the settings?

Most likely, they were saved only in the local memory of the phone (“Device Memory”), and not in the Google account or on the SIM card. When resetting (Factory Reset), the partition with user data is completely cleared. Always check where the new contact is saved.

How to find the contacts file on a phone without root?

Without root access, you will not find the system .db file. The only file available to you is the one you created yourself through the Export function. Look for it in the “Downloads” folder or in the root of the internal memory with the extension .vcf.

Is it possible to transfer contacts from Android to iPhone via a file?

Yes, this is one of the easiest ways. Export your contacts on Android to a VCF file, send it to yourself via email or instant messenger, open it on your iPhone and select “Add all contacts.” The iOS system understands this format perfectly.