Modern mobile device operating systems provide many capabilities, but standard developer tools often limit access to deep system settings. If you want to get full control over your gadget, the ability to make full backups or install custom firmware, you will need custom Recovery. The standard recovery menu, which is preinstalled by the manufacturer, can only do basic operations such as resetting settings to factory settings or installing official updates.

Installing third-party recovery opens up completely new horizons for the user. You can save images of the entire system, clean system partitions from junk that cannot be removed normally, and even flash modified kernels to overclock the processor. However, before starting the procedure, you should understand that any manipulations with system partitions carry certain risks that require responsibility and care.

In this article we will analyze in detail the preparation process, the necessary tools and a step-by-step algorithm for replacing stock recovery with an advanced solution. We will discuss popular app options, such as TWRP or OrangeFox, and methods for introducing them into the deviceโ€™s memory. We will also touch on security issues and how to return everything to its original state in case of failure.

Preparation of the device and necessary tools

The first step towards modifying the system is thorough preparation of the workplace and the smartphone itself. You will need a computer with a Windows, macOS or Linux operating system, as well as a high-quality USB cable, preferably an original one, to avoid connection problems. An unstable connection can interrupt the process of writing data to critical sections of memory, which will lead to inoperability of the device.

You must also make sure that USB debugging mode is activated on your device. To do this, go to Settings โ†’ About phone and quickly click on the build number 7 times until a notification appears indicating that you have become a developer. After that, in the new menu For developers find the item USB debugging and activate it. Without this step, the computer will not be able to send commands to the phone through the ADB interface.

Another critical step is unlocking the bootloader. Most manufacturers, such as Xiaomi, Samsung or OnePlus, block the ability to write to system partitions by default. The unlocking procedure is unique for each brand and often requires obtaining a special code or waiting a certain time after linking your account.

โš ๏ธ Attention: The bootloader unlocking procedure almost always leads to the complete deletion of all data from the deviceโ€™s internal memory. Be sure to back up important photos, contacts and documents before starting work.

After unlocking, you will need to download the Platform Tools package from the official Google website. This archive contains utilities adb and fastboot, which are the main tool for communication between a PC and a smartphone in service modes. Unpack the archive into a convenient folder, for example, the root of drive C, so that the paths to the files are short and clear.

โ˜‘๏ธ Ready for the procedure

Done: 0 / 5

Choosing a suitable Recovery image

The custom recovery market is quite wide, but not all the images are compatible with your specific phone model. The most popular and functional solution today is TWRP (Team Win Recovery Project). It has a convenient touch interface, supports exFAT file system and allows you to connect external drives via OTG.

In addition to TWRP, there are other alternatives that may be suitable for specific tasks. For example, OrangeFox is often chosen by users of Xiaomi i Redmi devices due to its optimized performance with data encryption. For older devices or those where minimalism is important, CWM (ClockworkMod)may be suitable, although its development has practically stopped.

When searching for an image, it is extremely important to pay attention to the code name of your device. Firmware designed for Samsung Galaxy S10 (beyond1)will not be suitable for S10+ (beyond2), despite the external similarity of the models. Using an incompatible file can lead to a โ€œbrickโ€ - a state where the phone stops turning on at all.

๐Ÿ“Š Which Recovery are you planning to install?
TWRP (classic)
OrangeFox (for Xiaomi)
PitchBlack (for Samsung)
Another custom
I donโ€™t know, I need advice

You should download images only from trusted sources. The official website of the TWRP project, forum XDA Developers or telegram channels of specific devices are the most reliable places. Avoid dubious file hosting services where the file could be modified by attackers or damaged during download.

Installation via Fastboot mode

The most common and reliable installation method is using the Fastboot fast boot mode. To enter this mode, you usually need to turn off the phone and hold down a combination of buttons, most often this Volume Down + Power. On some models OnePlus or Oppo may need to hold both volume buttons.

After connecting your phone to your computer and entering Fastboot mode, open Command Prompt or Terminal in your tools folder. Check the visibility of the device with the command:

fastboot devices

If you see the device serial number in response, it means the drivers are installed correctly and the connection is established. Now you can start recording the image. The command for temporarily downloading recovery without installing it permanently looks like this:

fastboot boot twrp-3.x.x-x-device.img

This method is convenient for testing: if after downloading you see the TWRP menu, then the image is suitable. To write it to the device memory forever, use the command:

fastboot flash recovery twrp-3.x.x-x-device.img

However, on many modern devices with dynamic partitions (A/B partition scheme), the command flash recovery may not work or overwrite only one slot. In such cases, manufacturers often block writing to the recovery partition directly. Then you have to use the command boot for the first boot, and within the TWRP menu select installation to permanent memory.

โš ๏ธ Attention: On devices with A/B partitions (for example, Google Pixel, new Xiaomi), the firmware is often written to an inactive slot. Make sure that you switch slots or use special scripts to install in both partitions.

What to do if Fastboot does not see the device?

Most often the problem lies in the drivers. Try installing generic Google USB Drivers or manufacturer-specific drivers (for example, Samsung USB Driver). Also check the cable and USB port; it is advisable to use the USB 2.0 port on the back of the motherboard, since USB 3.0 ports sometimes cause conflicts when transmitting service commands.

Alternative installation methods

It is not always possible to use a computer or Fastboot mode. In such cases, installation methods directly from the device itself come to the rescue. One of the most popular ways is to use the application Flashify. For it to work, you will need superuser rights (Root), which must already be obtained on the device.

The process in Flashify is as simplified as possible: you download the recovery image, open the application, select the "Recovery image" item, specify the downloaded file and confirm the reboot. The application will automatically backup the current stock recovery and write a new one. This is convenient, but requires a working Android system.

Another option is to use the terminal inside Android. If you have access to the console through a terminal emulator, you can use the utility dd. This method is considered โ€œhardcoreโ€ and requires exact knowledge of the path to the block recovery device.

su

dd if=/sdcard/twrp.img of=/dev/block/bootdevice/by-name/recovery

Here /dev/block/bootdevice/by-name/recovery is a path that may differ on different processors (Qualcomm, MediaTek, Exynos). An error in one letter of the path can lead to the boot image being overwritten, after which the phone will no longer boot. Use this method only if you know exactly the partition structure of your device.

๐Ÿ’ก

If you use the method via the terminal, be sure to check the path to the recovery partition using the ls -l /dev/block/bootdevice/by-name/ command before writing. An error in the path is fatal.

Initial setup and work in TWRP

After successful installation and the first boot into the custom menu, you will be faced with a screen for selecting a language and password. If your phone has data encryption set up, TWRP will ask you to enter your PIN or screen unlock pattern. Without this step, access to the internal memory will be closed, and you will not be able to flash anything new.

An important point is the choice of mode for working with the file system. When you first launch TWRP, you'll often be prompted to choose between "Keep Read Only" and allowing changes. For full operation, you must click the Allow Modifications (Allow changes) button. If you select read-only mode, you will not be able to install a patch to save root access or new firmware.

Several key sections are available in the main menu. Section Backup allows you to create a complete copy of the system. It is recommended to select sections Boot, System, Data and EFS (or Modem). The EFS partition contains unique IMEI identifiers, and its loss may make it impossible to connect to a cellular network.

Section Description Importance of backup
Boot System kernel and ramdisk Critical
System Android operating system files High
Data Custom applications and settings Medium (takes up a lot of space)
EFS / Persist Sensors, IMEI, network settings Critical important

Section Wipe is designed to clear memory. The function Advanced Wipe allows you to selectively format sections Dalvik / ART Cache, Cache, System and Data. This must be done before installing custom firmware (Clean Flash) to avoid file conflicts and errors in the operation of the new system.

๐Ÿ’ก

Never format the Data partition immediately after the first installation of TWRP, unless you are planning a complete flashing. This will delete all files and may reset the encryption that required re-configuration.

Possible problems and solutions

When modifying a device, users often encounter a number of common problems. One of the most common is a reboot loop (bootloop) after installing new firmware or kernel. If the phone constantly reboots and cannot boot the system, you need to go to Recovery and perform a full reset (Format Data), and then reinstall the firmware.

Another common problem is the lack of access to the internal memory in Recovery mode ("Storage mounting error"). This often happens due to a file system change F2FS or encryption problems. The solution is to format the Data partition inside TWRP, but this will again lead to data loss.

A situation may also arise when the custom Recovery is spontaneously replaced with the stock one after the first reboot. This occurs due to the protection mechanisms of some manufacturers (for example, Samsung Knox or MIUI). In such cases, it helps to use special patches that block automatic replacement, or installation through specialized scripts in TWRP itself.

โš ๏ธ Attention: If your device has stopped responding to buttons and the screen is black (Hard Brick), software methods may not help. You will need to use emergency recovery modes such as EDL (Emergency Download Mode) for Qualcomm or Odin for Samsung, which often requires an authorized account or paid tools.

Remember that the developer community is constantly updating its products. What worked on Android 10 may not work correctly on Android 13 due to changes in partition structure and encryption protocols. Always check the date of the last update of the Recovery image and read comments from users with your phone model.

Why does TWRP not see the SIM card after flashing?

This is not a recovery error, but a consequence of the loss of the EFS or Modem partition due to incorrect firmware. Restore the backup of the EFS partition made before the start of the experiments to return the ability to make calls.

Frequently asked questions (FAQ)

Will the warranty expire after installing custom Recovery?

In most cases, yes. The fact of unlocking the bootloader and modifying system partitions is recorded at the fuse level (for example, Samsung Knox tripped 0x1). This is grounds for denial of warranty service, even if you return the stock firmware back. Physical traces of tampering are not required, the software flag changes forever.

Is it possible to get root access through custom Recovery?

Yes, this is one of the main functions. After installing TWRP, you can flash the archive with the utility Magisk or SuperSU. Magisk is preferable, as it uses a system of system partitions (systemless), which allows you to hide the presence of root access from banking applications and Google Pay services.

Is it safe to install banking applications with custom Recovery?

The default is no. Banking applications check the integrity of the bootloader and the presence of a modified Recovery. For them to work, you need to use the hiding functions in Magisk (Zygisk, DenyList) and, possibly, reflash the modules that disguise the device status as a serial certificate.

What to do if you forgot the graphic encryption key in TWRP?

Unfortunately, it is impossible to decrypt the Data section without the key due to the Android encryption algorithms used. The only way out is to format the Data partition inside Recovery, which will lead to the complete loss of all user data, but will restore access to file management.

Is it possible to update Android OTA with custom Recovery installed?

Standard OTA updates (over the air) are most often not installed on devices with an unlocked bootloader and custom Recovery. The system checks the integrity of the partitions and aborts the installation. Usually you have to download the full firmware image and install it manually via Recovery mode.