How to Root OnePlus Running ColorOS 12 Android 12 (via Magisk)

In this post, we will show you the steps to root your OnePlus device running ColorOS 12 Android 12 via Magisk. There are many OEMs out there who are running custom OS fast. From OneUI to MIUI, from RealmeUI to EMUI, the list goes on. However, it was the OnePlus offering that managed to rise to the top.

Managing to strike the perfect balance between desired feature sets, customization and tweaks, and overall stability of the device did not leave much to be desired. But why are we saying all this in the past? Well, that’s because of OEM’s decision to stop using its own OxygenOS and instead adopt one of the parent company’s other subsidiary’s UI.

Literally disappointing, OnePlus has now decided to jump on the bandwagon on Oppo’s ColorOS. And we, as consumers, have nothing to say. As this is going to be the way forward now, let’s get used to it, both in terms of general use as well as in custom development. And yet, we will focus on the latter domain. In this guide, we will show you the steps to root your OnePlus device running ColorOS 12 Android 12 via Magisk.

How to Root OnePlus ColorOS 12 Android 12 via Magisk

The instructions below are listed in separate sections for ease of understanding.

STEP 1: Install Android SDK

First, of all, you will have to install the Android SDK Platform Tools on your PC. This is the official ADB and Fastboot binary provided by Google and is the only recommended one. So download it and then extract it to any convenient location on your PC. Doing so will give you the platform-tools folder, which will be used throughout this guide to root your OnePlus device running ColorOS 12 Android 12 via Magisk.

STEP 2: Enable USB Debugging and OEM Unlocking

Next up, you will also have to enable USB Debugging and OEM Unlocking on your device. The former will make your device recognizable by the PC in ADB mode. This will then allow you to boot your device to Fastboot Mode. On the other hand, OEM Unlocking is required to carry out the bootloader unlocking process.

So head over to Settings > About Phone > Tap on Build Number 7 times > Go back to Settings > System > Advanced > Developer Options > Enable USB Debugging and OEM Unlocking.

STEP 3: Unlock Bootloader

Next up, you will also have to unlock the device’s bootloader. Do keep in mind that doing so will wipe off all the data from your device and could nullify its warranty as well. 

STEP 4: Download Stock Firmware

  1. Now download the stock firmware for your device from the below link
  2. If the downloaded firmware is in JAR, then change its extension to ZIP (right-click > Rename).

STEP 5: Extract OnePlus ColorOS payload.bin

  1. Once you have changed the extension from JAR to ZIP, extract it to any convenient location on your PC.
  2. Doing so shall give you a couple of files, including the payload.bin file which will be used to root your OnePlus device running ColorOS 12 Android 12 via Magisk.
  3. So extract this payload.bin file to get the boot and vendor_boot files.
  4. Once the extraction is complete, copy the boot.img and vendor_boot.img files from there and transfer them to your device.
  5. Likewise, transfer the vbmeta.img file to the platform-tools folder on your PC. Now move over to the next step to root your OnePlus device running ColorOS 12 Android 12 via Magisk.

STEP 6: Patch Boot and Vendor_Boot via Magisk

  1. To begin with, download and install the Magisk App onto your device.
  2. Then launch it, tap on the button Install next to Magisk, and choose Select and Patch a File.
  3. Now navigate to the boot.img file, select it, and tap on the Let’s Go button situated at the top right.
  4. The patching process will now begin and will take a few seconds.
  5. Once done, go back to the Magisk home screen and again choose Select and Patch a File.
  6. This time, select the vendor_boot.img file and tap on the Let’s Go button situated at the top right.
  7. Wait for the patching to complete. Once done, open File Explorer and go to the Downloads folder.
  1. Then copy both the patched boot.img and vendor_boot.img files and transfer them to the platform-tools folder on your PC.
  2. Once that is done, go to the folder where you had extracted the payload.bin file. Then copy the vbmeta.img file from there and transfer it to the platform-tools folder as well.
  3. Now simply the name of these files so that it becomes easier to type in the CMD window. So rename the boot file to magisk_boot.img and vendor_boot file to magisk_vendor.img.

STEP 7: Boot OnePlus to Fastboot Mode

  1. Connect your device to the PC via USB cable. Make sure USB Debugging is enabled.
  2. Then head over to the platform-tools folder, type in CMD in the address bar, and hit Enter. This will launch the Command Prompt.
  1. Type in the following command in the CMD window to boot your device to Fastboot Mode
adb reboot bootloader
  1. To verify the Fastboot connection, type in the below command and you should get back the device ID.
fastboot devices

STEP 8: Flash Patched Boot and Vendor_Boot IMG | Root ColorOS 12 Android 12

  1. To begin with, execute the below command to flash the Magisk Patched Boot.img:
fastboot flash boot magisk_boot.img
  1. After that, flash the Magisk patched Vendor_Boot file via the below command:
fastboot flash vendor_boot magisk_vendor.img
  1. Next up, use the below command to flash vbmeta and hence disable the verification:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
  1. Once that is done, you may now reboot your device to the OS via the below command:
fastboot reboot

Enjoy.

[su_button url=”https://t.me/getdroidroms” target=”blank” style=”flat” background=”#0064c9″ size=”7″]Join us on telegram[/su_button]

You May Also Like

More From Author

+ There are no comments

Add yours

Leave a Reply