Android Software

How to root Android


Android is an open operating system. This means that not only can developers take its source code and create modified versions of it, but also that we users can customize the software of our portable devices while being able to count on a very high degree of flexibility. To increase our freedom of action even further, we can use an unlocking procedure, called root , which allows us to bypass all the restrictions that normally prohibit access to the deeper areas of the system.

To put it simply, when you root Android you become 100% “master” of your device. You can modify the operating system files, you can “push” the phone’s performance by altering its hardware parameters (e.g. the processor frequency) and you get the possibility of using applications that would not normally work, such as those that allow you to create full system backups or control the terminal remotely.

The procedure is completely legal but, in most cases, it invalidates the warranty of the phone (or tablet) on which it is applied: it all depends on the policies implemented by the manufacturer. Furthermore, you must be careful to follow the specific procedure for your device, in order to avoid “brick” of the same (i.e. the temporary or definitive inability to use it): unfortunately, there is no standard one, valid for all terminals, precisely because of the enormous amount of devices and variants of Android that exist. In any case, during this guide I will briefly explain the steps you will have to take if you decide to unlock your smartphone or tablet: happy reading and good luck with everything!


Rooting Android: risks and benefits

Rooting Android: risks and benefits

The possibility of pushing your Android device beyond the software (but also hardware) limits set by the manufacturer excites you quite a bit and this is why, more than ever, you are extremely curious to understand how to unlock root permissions on your device.

Although obtaining elevated privileges can be an advantage for those who are (or want to become) a “geek” and customize their device to the highest levels, it is right to be aware of the fact that the root procedure is not always immediate — in reality , it almost never is — and that it requires time , patience but above all great attention and precision . In fact, a single error in any step is enough to completely block the device, rendering it unusable .

Unlocking a device’s root privileges may also void its warranty (depending on the manufacturer’s usage policy) but, more importantly, makes it vulnerable in terms of security . Since the procedure involves unlocking extremely delicate parts of the operating system, a distracted tap is enough to allow an app, even unconsciously, to access or alter delicate parts of the memory, which could contain sensitive data or, in the worst case scenario, security information.

Another potential consequence of the root procedure is to increase the chances of contracting malware such as spyware , trojans , adware , viruses or, even worse, ransomware that are extremely difficult to eradicate: these elements could lead to very unpleasant consequences, including the obligation to reset your device or, even worse, the irreparable loss of stored data.

Still talking about data, you should be aware that the root procedure almost always involves formatting Android’s memory: as you will soon discover, this is a direct consequence of unlocking the bootloader , which cannot be bypassed in any way. way.

In light of what you have learned, weigh the risks and benefits of the root and carefully evaluate whether the procedure is right for you; finally, if you have little experience with the world of Android, my advice is to get assistance from a more knowledgeable person on the subject, at least the first time: this will certainly reduce the chances of running into problems caused by distraction, inexperience or , worse yet, haste.

Root dictionary

How to root Android

Again, before moving on to practice, it is good practice to familiarize yourself with some specific terms related to rooting on Android: therefore, take a few minutes of free time and read this short root dictionary, if we want to call it that.

  • Root — technically, root allows you to use Android with administrator privileges. This, as previously mentioned, allows you to have access to system areas that are normally inaccessible and therefore offers the possibility of using functions and apps that users with standard privileges cannot use.
  • ROMs — are the modified versions of Android that developers “cook” and make available to the public. They are almost always supplied with root privileges already unlocked and can contain various customizations, such as software optimizations to make the device run faster or graphic themes different from the default Android one. You have to be very careful to download one that is suitable for your device.
  • Bootloader — is the software that starts as soon as you turn on your smartphone (or tablet) and provides the device with the instructions necessary to start the operating system, i.e. Android. It is usually blocked and does not allow the installation of customized ROMs or Recovery, so you must unlock it using a procedure that we will analyze a little later. Be careful: unlocking the bootloader invalidates the device’s warranty and deletes all apps and data saved on the device.
  • Recovery — is software that allows you to perform various system operations, such as installing ROMs or backing up Android devices. The one present “as standard” on smartphones and tablets on the market is very limited, so you must install an alternative one (another topic that we will discuss in a few lines).
  • Kernel — the kernel is the heart of Android (as well as any other operating system), the one that manages communication between the software and the hardware. It is possible to install custom ones to increase the performance of the device but this is a fairly risky operation for the stability of the system.
  • Radio — is that part of the firmware that is responsible for connecting the device’s software with the hardware linked to the Wi-Fi connection, the data network, the voice line and the GPS. There are customized versions available on the Internet that should increase network performance, but again these are high-risk modifications.
  • Gapps — Android custom ROMs, for rights reasons, cannot contain Google applications (Play Store, Gmail, etc.). To fill this gap, you can download a package called Gapps from the Internet which contains them all.
  • Flash — “flash” is a term that is used as a synonym for “install” when it comes to inserting an Android ROM, kernel or recovery onto your device. It therefore means installing a customized version of Android, a Recovery or a kernel, on your smartphone or tablet.
  • Nandroid — is a complete backup of the terminal containing apps, data and settings. It can only be done after installing an alternative Recovery.
  • ADB – acronym for Android Debug Bridge , is software that allows you to communicate with Android devices from the PC via command line. It is part of the Android SDK, that is, the official package that contains all the tools for Android developers, and its presence is fundamental in the root procedure of many devices.
  • Magisk/SuperSU — are the software that, once rooted, allow you to manage the permissions of the various applications. In fact, you will decide which apps will be able to access the system using root permissions (therefore administrator privileges) and which will not, through convenient warnings that will appear on the screen when you try to run them.
  • Fastboot — is an Android boot mode that allows you to edit system files when the device is connected to a computer via USB cable. To activate it, you need to turn off the terminal and press the Powerand keys at the same time Volume -, or act from the Command Prompt, via ADB.
  • Recovery mode — boot mode that allows you to access Recovery. On some devices it is recalled by pressing Volume +and Power, on others by pressing Volume -and Powerand then selecting the option Recoveryfrom the menu that opens.
  • USB debugging — is a way to connect Android to your computer via USB cable required by most root software. To activate it, you need to go to the Android settings, select the item Info sul telefonoand press on the wording Numero buildseven consecutive times to bring up the menu Opzioni sviluppoin which the USB debugging function is located.

How to root Android

How to root Android

After having addressed a brief but concise overview of the theoretical part, the time has come to show you, in practice, how to root Android . I have already told you, in the opening lines of this guide, that each device has its own procedure and that it is not always possible to apply “standard” methods, which allow you to achieve the desired result.

However, the sequence of actions to be carried out is always the same (although the ways in which they are completed can vary greatly from one device to another) and, in almost all cases, requires the availability of a computer . In any case, let me tell you what the generally applicable “guidelines” are.

First of all, you need to prepare the PC from which to act, downloading three essential elements: ADB , the official Android utility that allows you to issue commands from the computer; Fastboot , another official tool capable of making changes to the boot area of ​​the smartphone or tablet operating system; and, finally, the complete drivers of the device in question, so that it is recognized in all the necessary modes (ADB, Fastboot , external storage, etc.).

Once the download and installation of the software listed above has been completed, you must activate the USB debugging mode on the device, so that it can be controlled from the command line and, subsequently, proceed with unlocking the bootloader , in order to allow the installation of a customized Recovery, essential to unlock root permissions.

Unfortunately, not all bootloader unlocking procedures are immediate: many of them (such as those dedicated to Sony , Motorola and some Xiaomi devices ), in fact, require authorization from the device manufacturer, after obtaining a code, the which could be provided even days after the request. However, some smartphones, such as those of the Android One line , allow you to unlock the bootloader in Fastboot mode by activating a specific option in the development menu.

However, I remind you that the aforementioned operation involves the complete loss of the data stored in memory: for this reason, before proceeding, make a preliminary backup of the same.

Once the bootloader has been unlocked, it is necessary to install a customized Recovery , then download the app to enable root permissions and flash it via the Recovery itself. Once this phase has been completed, just restart the device to take advantage of root permissions.

To give you an even more precise idea of ​​how to obtain root permissions on Android, I can explain how to act on a specific model of smartphone that I have, namely the Xiaomi Mi A1 , from the Windows operating system , using TWRP Recovery and the Magisk root app .

The Xiaomi Mi A1, if you had never heard of it, is a phone belonging to the Android One line , that is, those devices whose bootloader can be unlocked in a few seconds, directly with Fastboot; the procedure can also be easily replicated on other smartphones from the Android One line and on devices from the Pixel family, with the exception of a few small structural details, such as installing the specific drivers for the device and downloading the exact version of TWRP

Preparing the computer

How to root Android

The first step to take consists of preparing the PC from which to act, downloading the ADB and Fastboot tools onto it : the latter allow you to operate, respectively, on Android and on the device’s boot area via the Command Prompt .

Both software are incorporated into the Android Studio development suite but, for simplicity, I chose to use a basic version of the same, available on the XDA forum: therefore go to this web page , click on the Download version XXX Portable link and press the buttons Click Here to Start Download and Primary Download , visible on the next page, to obtain the compressed archive.

Once the package has been downloaded, extract it into a folder of your choice, easy to reach and remember (and possibly without spaces): you will need it soon.

Now, in order to avoid problems during the action phase, it is recommended to equip yourself with specific Fastboot drivers for the device in your possession: generally, you can achieve this by downloading and installing the official management/diagnostic software of your smartphone or tablet. In my case, it is enough to download the official Mi Unlock tool and set it to install device drivers.

So, open this website and click on the Download Mi Unlock button to start downloading the package containing the necessary program; subsequently, extract the compressed archive into the folder of your choice, open the latter and launch the miflash_unlock.exe file that resides inside it.

Once you reach the program’s welcome screen, press the Agree button to accept the terms of use, then click on the gear icon located at the top right and then on the Check button , located next to the wording Click the button to install the drivers , to start installing Fastboot drivers.

Finally, click the Yes button twice consecutively and, when you see the Connect device again message , connect your smartphone to the PC using the USB cable . Finally, wait for the drivers to be completely installed, click on the Close button and close the Mi Unlock window.

Unlocking the bootloader

How to root Android

To be able to start operating the device via the computer in ADB and Fastboot mode, you need to enable the Android development options and, within them, USB debugging . To proceed, tap on the gear symbol located on the Home screen or in the device drawer, to open the Android Settings , tap on the System and Phone Information items and tap on the wording Build number seven consecutive times until you see a message notifying you that you have become a developer .

Now, return to the previous menu, reach the Advanced > Development Options sections and move the lever next to the USB Debugging item to ON , responding affirmatively to the next warning.

At this point, you are ready to unlock the bootloader : since we are working on an Android One smartphone, you will not have to request any code, but simply prepare the device for unlocking via Fastboot. To do this, again from the menu dedicated to Development Options , move the lever corresponding to the OEM Unlock item to ON and, aware that this operation involves the deactivation of some advanced system protection mechanisms, respond in the affirmative to the warning that comes to you proposed.

Now, keeping the phone connected to the computer, open the ADB/Fastboot folder that you extracted previously, click on the cmd-here executable file and issue, within the Command Prompt window that opens, the instruction adb devicesand press Enter : following this operation, an authorization request should appear on the Android screen.

When this happens, place the check mark next to Always allow from this computer and tap the OK button to provide the necessary permissions; now, return to the Command Prompt window open on your computer, type the command again adb devicesand check that the device is accessible (next to its ID, you should see the word device ).

Now, to access the Android bootloader, type the command adb reboot bootloaderand press Enter : after a few seconds, the connected device should restart and display the bootloader. When this happens, give the command fastboot devicesand check that the smartphone or tablet has been correctly recognized.

If the outcome of the check is positive, you can proceed with unlocking the bootloader: aware that this operation will lead to the complete loss of the data on the device, now type the command fastboot oem unlockand press Enter : following this operation, the smartphone (or the tablet) should reboot several times and start memory recovery .

This operation may take a few minutes and the same thing may happen at startup immediately after the reset: don’t worry, it’s perfectly normal. I also warn you that, before each future boot, you may see a worrying warning message regarding the potential dangers associated with unlocking the bootloader.

In any case, when Android becomes available again, carry out the initial configuration of the device and activate the development options and USB debugging again , as done previously. Don’t close the Command Prompt window yet and don’t disconnect your device from your PC, you’ll need them soon.

Installing Recovery

How to root Android

After unlocking the bootloader, you are ready to install customized Recovery: personally, I recommend TWRP , an excellent Recovery with an interface also suitable for less experienced users, with touch-screen support and updated on a regular basis.

To obtain it, connect to its Home Page, click on the Devices item located at the top and use the following pages to indicate the brand and model of your device; To speed things up, you can use the search field visible at the top. Be careful, this is a very delicate phase: downloading and flashing a file that is unsuitable for your device can irreparably compromise its functioning.

In any case, once you reach the download page of the correct version of TWRP, click on the Primary (Europe) button visible in the Download Links box and use the links available on the next page to download the most recent ROM file, in .img format . Once the download is complete, copy the file obtained into the ADB/Fastboot folder .

Once this operation is completed, recall the Command Prompt that you had opened previously and check that the Android device is still connected by typing the command adb devices; if asked, authorize communication between the two devices again, responding affirmatively to the warning that appears on the smartphone or tablet display.

Once this is done, issue the command adb reboot bootloaderto access Android Fastboot mode, verify that the device has been recognized using the command fastboot devicesand identify the active partition , issuing the command fastboot getvar current-slot: Recovery must be installed on the one that is not . Therefore, if the result of the previous command is of the type current-slot: b , you will have to intervene on partition a .

Therefore, assuming that partition a is the one that is currently inactive, type the command fastboot flash boot_a nomefile.img, replacing filename.img with the name of the TWRP Recovery downloaded just now (e.g. twrp-3.5.0_9-0 -tissot.img ) and press Enter , to copy the Recovery to the appropriate memory area. Now, to ensure that the device starts from it, set the partition on which you operated as active, using the command fastboot set_active a(or b, depending on the case).

How to root Android

Finally, take your smartphone or tablet, press and hold the Volume+ button and, at the same time, type the command fastboot rebootin the Command Prompt: if everything went well, after a few seconds, the Android screen should display the screen TWRP welcome.

When this happens, tap on the Select Language button , select the box located next to the language you intend to use (presumably Italian ) , touch the OK button and place the check mark next to the item Do not show this screen again at startup . Finally, tap the Keep read-only button and that’s it: you can finally use Recovery to obtain root permissions.

At this point, you can easily close the Command Prompt window, but don’t disconnect the phone/tablet from the PC yet: you will have to use the latter to transfer the file responsible for unlocking root permissions to the Android device.

Installing Magisk and obtaining root

Installing Magisk and obtaining root

Don’t give up, it’s almost done: all you have to do is download the app that allows you to obtain root and flash it via the newly installed Recovery. Therefore, tap on the Mount button , located on the TWRP screen , place the check mark next to the Data folder and touch the Enable MTP mode button , to ensure that the computer is able to access the phone’s internal memory.

Now, return to the PC and download Magisk , the application I chose to unlock root permissions: then open this website , click on the link visible in the Assets box and, once the file has been downloaded, copy it to the Android internal memory. You can access the latter by launching File Explorer and going to This PC > [device name] > Internal storage .

Once the copy is complete, return to Android, tap the Disable MTP button resident on the TWRP screen and go back , tapping the triangle symbol located at the bottom left, to display the main Recovery panel again. If you wish, you can disconnect your Android device from your computer.

Now, tap on the Install button , then on the name of the archive copied earlier (e.g. ) and, after selecting the box next to the wording Restart after installation is completed , swipe from left to right on the Swipe to install bar . Following this operation, the Magisk file will be flashed and, if successful, the Android device will reboot automatically.

We’re finally there: on the next boot, you should have obtained root permissions. To verify the correct success of the procedure, download the Root Checker app from your device’s store and launch it: the request to use root permissions, which should be made by the application, is synonymous with success!

How to root Android without PC

How to root Android without PC

The procedure that I have illustrated to you throughout this guide, to avoid errors, should allow you to unlock root permissions in almost all cases. However, if you don’t have a computer available, you should know that in some cases it is possible to root Android without a PC , using a series of third-party apps designed for this purpose, in just a few taps.

However, I do not advise you to go down this path, mainly for two reasons: the first is that applications of this kind are not available on the Play Store or on other “official” markets , but should be downloaded from third-party websites and often of dubious seriousness , therefore I cannot give you guarantees regarding the security and integrity of the files in question.

Secondly, the one-tap root procedure is not always successful: everything depends first of all on the brand and model of the device you own, the presence or absence of advanced system protections and, above all, the version of Android in use and the partition scheme applied by it: take this into account.

This does not apply, however, to well-known apps such as Magisk Manager : the latter, in fact, can be used to flash the Magisk file on Android, in just one tap. However, for the procedure to be successful, it is essential that the device’s bootloader has already been unlocked and that there is a customized Recovery on it : to satisfy these conditions, as you have discovered previously, the computer use.

Related Posts

windows 11

How to uninstall a program

Look at it: your computer’s hard drive is so full it’s about to burst! Explain to me why you haven’t taken action yet. There are very heavy programs that you haven’t used for months: why haven’t you deleted them? Maybe I understood! You’re new...
Android smart tv

Best Android TVs: buying guide (January 2024)

You are looking for a Smart TV to better enjoy your favorite contents and access the most famous streaming apps and you have heard good things about Android TV , the operating system that brings the experience of the Google operating system, now widespread...
Android apps

How to uninstall Android apps

Excited by the purchase of your first Android smartphone , you stocked up on apps: you downloaded everything you could find in the Play Store and now, as widely expected, you no longer have the space to do anything. Given the situation, there...