Security certificates on Android play a key role in protecting connections, verifying the authenticity of sites and applications. However, sometimes they become a source of problems: they block access to corporate resources, cause connection errors, or simply take up space after the applications that installed them are uninstalled. Unlike cache or temporary files, certificates require careful handling - their incorrect deletion can disrupt work VPN, Wi-Fi with Enterprise authentication or even system updates.

This article will help you figure out which certificates can be deleted without risk, and which ones should not be touched. We will look at standard methods through the settings menu, advanced methods using ADB, and also explain how to restore deleted certificates if something goes wrong. We will pay special attention to the difference between user and system certificates this is critical for the security of the device.

Why delete certificates on Android?

At first glance, certificates seem to be harmless files, but their accumulation can lead to serious problems:

  • ๐Ÿ”’ Security conflicts: Outdated or compromised certificates can allow attackers to intercept traffic (for example, through attacks MITM).
  • ๐Ÿ“ต Connection errors: If the certificate for corporate Wi-Fi or VPN has expired, the device will not be able to connect to the network.
  • ๐Ÿ—‘๏ธ Garbage after uninstalling applications: Many apps (for example, banking or instant messengers) install their certificates, but do not always delete them during uninstallation.
  • โš ๏ธ Test certificates: Developers often add temporary certificates for debugging, which then they forget to delete.

However, not all certificates can be deleted without consequences. For example, system certificates signed by the manufacturer (Samsung, Google, Xiaomi) are responsible for checking OS updates and the operation of key services. Their deletion can lead to "briku" the device being unable to boot. firmware.

โš ๏ธ Attention: On some devices with Android 12+ i Android 13+ deleting system certificates may cause a failure. Before proceeding, check whether the certificate is used by critical ones. applications (for example android.process.acore. Before proceeding, check whether the certificate is being used by critical applications (for example, Google Play Services).
๐Ÿ“Š Have you ever encountered problems due to certificates on Android?
Yes, there were errors connecting to Wi-Fi
Yes, corporate mail did not work
No, there have never been problems
I donโ€™t know what certificates are

Types of certificates on Android: what can be deleted and what canโ€™t

All certificates Android are divided into three categories. Their difference is in the level of access and the consequences of deletion:

Type. certificate Where is it stored Can it be deleted Consequences of deletion
Custom Folder /data/misc/user/0/cacerts-added/ Yes Loss of access to resources for which a certificate was installed (for example, a corporate portal).
System (pre-installed) Folder /system/etc/security/cacerts/ No (without root) Infringement of updates, Google Play, system applications.
Applications (private) Folder /data/data/[package_name]/app_certificates/ Yes (will be deleted with the application) The application may stop working if the certificate is critical for its functions.

The safest ones to delete are user certificates. They are installed manually (via files .crt or .p12) or automatically when connecting to secure networks. It is not recommended to touch system certificates unless you are an experienced user with root-access i. backup.

A special case is certificates installed via Android Enterprise or Knox (on Samsung). are tied to company security policies and block deletion without special rights.

๐Ÿ’ก

Before deleting a certificate, check its purpose: open the file in a text editor and find the fields Issuer (who issued it) and Subject (what it is intended for).

How to delete user certificates through settings Android

The standard method is suitable for most devices without root. The instructions are relevant for Android 9โ€“14, but the location of menu items may vary slightly depending on the shell (MIUI, One UI, ColorOS etc.).

โ˜‘๏ธ Preparation to deleting certificates

Done: 0 / 3
  1. Open Settings โ†’ Security โ†’ Advanced settings โ†’ Encryption and credentials โ†’ User credentials (on some devices the path may be Settings โ†’ System โ†’ Advanced โ†’ Credentials).

  2. In the section "User credentials" or "Credential Data Storage" find the tab Certificates (sometimes called CA Certificates).

  3. Select the certificate you want to delete and click on it. The system will show information about the issuing center (Issuer) and the expiration date. actions.

  4. Press the button Delete (or Revoke) and confirm the action. Some devices may request PIN code or pattern key.

If the certificate is not displayed in the list, it may be installed as system or linked to the application. In this case, you will need ADB or root access.

โš ๏ธ Attention: On devices with Android 11+ and active function "Reset protection" (Factory Reset Protection) removal of some certificates may require entering account data Googlelinked to the phone.

Removing certificates via ADB (without root)

If the certificate is not deleted through the settings menu or you want to clear the storage completely, this will help Android Debug Bridge (ADB). This method does not require superuser rights, but access to USB debugging is required.

First prepare the device:

  1. Activate Developer mode: go to Settings โ†’ About phone โ†’ Build number and tap on it 7 times.
  2. Enable USB debugging in the menu For developers.
  3. Connect your phone to the PC and confirm trust in the computer.

Now run the commands in the terminal (or PowerShell on Windows):

adb shell pm list packages | grep -i "cert"

adb shell pm uninstall -k --user 0 com.android.credentialmanager # Resetting the credential manager

adb shell cmd credential reset_certificates

If you need to remove a specific certificate by name:

adb shell cmd credential remove_cert

To completely clear user certificates certificates (attention: this will delete manually added certificates!): all manually added certificates!):

adb shell rm -rf /data/misc/user/0/cacerts-added/*
What to do if ADB does not see the device?

1. Check if ADB drivers are installed for your phone model.

2. Try another USB cable (preferably the original one).

3. In the menu For developers enable the option USB debugging (security settings) and select Always allow from this computer.

4. Restart your phone and PC.

Removing system certificates (root required)

System certificates are protected from changes without superuser rights. Removing them may disrupt the operation of Google PlayOS updates or even lead to "soft-brick" (the device turns on, but does not boot completely). If you still decide to delete them, follow the instructions:

Step 1: Get root access using Magisk or another tool.

Step 2: Use a file manager with support root (for example, Root Explorer or FX File Explorer) and go to the folder:

/system/etc/security/cacerts/

Step 3: Find the certificate by name (for example, google_root_ca.crt) and delete it. Do not delete files with the extension .0 or .hash โ€”this may break the system integrity check!

Step 4: Reboot the device and check the stability of operation. If errors occur, restore the certificate from a backup or reflash the device.

โš ๏ธ Attention: On devices with Samsung Knox or Pixel s Verified Boot deleting system certificates may trigger a reset. eFuse and permanent blocking of some functions (for example, Samsung Pay or Secure Folder).
๐Ÿ’ก

Removing system certificates is a last resort. In 90% of cases, the problem can be solved by resetting user certificates or reinstalling the problematic application.

How to recover deleted certificates

If, after deleting the certificates, Wi-Fi, VPN or corporate applications stop working, try the following recovery methods:

  • ๐Ÿ”„ Reinstall the certificate: If you have saved the file .crt or .p12, import it again via Settings โ†’ Security โ†’ Install from storage.
  • ๐Ÿ“ฑ Reset settings network: Go to Settings โ†’ System โ†’ Reset โ†’ Reset Wi-Fi, mobile network and Bluetooth settings. This will return standard certificates for network connections.
  • ๐Ÿ”ง Recovery via ADB: If the certificate was a system one, try copying it from another device of the same model:
    adb pull /system/etc/security/cacerts/[filename] C:\backup\
    

    adb push C:\backup\[filename] /system/etc/security/cacerts/

    adb shell chmod 644 /system/etc/security/cacerts/[filename]

  • ๐Ÿ› ๏ธ Flashing: As a last resort, perform a factory reset or reflash the device via Odin (Samsung), Fastboot or SP Flash Tool.

For corporate devices, you may need to contact your IT department - some certificates are installed through MDMsolutions (for example, MobileIron, VMware Workspace ONE) and are not restored using standard methods.

Common errors and how to avoid them

When working with certificates, users often encounter typical problems:

  • ๐Ÿšซ "The certificate is not deleted": Check if it is blocked by politicians Android Enterprise. Try deleting it using ADB with the command adb shell pm clear com.android.credentialmanager.
  • ๐Ÿ”Œ "Wi-Fi does not work after deletion": Most likely, the certificate for 802.1X (Enterprise-network). Restore it or request a new one from the network administrator.
  • ๐Ÿ“ฑ "The device stopped booting" is required. data-i="231">: Check if it has expired. Also: This is a sign of damage to the system certificates. Reflash via Recovery Mode.
  • ๐Ÿ”’ "I canโ€™t install a new certificate": Check if it has expired. Also on Android 10+ you may need to unlock the bootloader (OEM Unlock).

If you deleted the certificate by mistake and donโ€™t remember its name, try finding the installation log in /data/misc/keystore (required root). Metadata about added certificates is stored there.

๐Ÿ’ก

Before mass deleting certificates, create a restore point in TWRP or make a backup of the folder /data/misc/user/0/cacerts-added/ via ADB: adb pull /data/misc/user/0/cacerts-added/ C:\backup\certs

FAQ: Frequently asked questions about certificates on Android

Is it possible to delete certificates installed by a banking application?

Yes, but this may lead to errors when logging into the application. Banks often use certificates to verify the authenticity of the device, reinstall it - the certificate will be installed automatically.

Why does corporate email (Exchange) not work after deleting the certificate?

Corporate email clients (for example, Microsoft Outlook or Gmail in Exchangemode) require certificates to encrypt the connection. Delete and re-add the account. โ€” the certificate will be installed automatically during setup.

How to find out which certificate blocks access to the site?

Open the site in Chrome, click on the lock icon in the address bar โ†’ CertificateIn the section Certification path The problematic certification authority will be indicated. Compare it with the list in Settings โ†’ Security โ†’ User credentials.

Can I delete Google certificates?

Technically yes, but this will disrupt the operation of Google Play, YouTube and other services. System certificates Google (for example, Google Internet Authority) are responsible for verifying SSL connections. Their removal will make the device vulnerable to attacks.

How to remove certificates on Android without password?

If the certificate is password protected (for example, .p12 or .pfx), it cannot be deleted or changed without entering the password. The only way is to reset all credentials via Settings โ†’ System โ†’ Reset โ†’ Reset credentials (phone PIN required).