OnePlus 3
Here's how to unroot OnePlus 3 OnePlus

If you like the customisation and smoothness of OxygenOS over any custom ROM your OnePlus 3 is currently running, you can revert the phone to the stock firmware. The process is quite simple: all you need to do is just unroot it by installing stock OxygenOS update via adb sideload option. The process will lock the bootloader of the phone again. Check out the following guide for detailed instructions.

How to unroot OnePlus 3

  • Download OxygenOS 3.2.1. You might rename this to ota.zip to make the further process a bit easier
  • Download stock recovery
  • Put the phone in fastboot mode by holding the Power and Volume Up buttons together. Alternatively, use the extended boot menu from Android to boot
  • Open Windows Command Prompt in Admin mode in the folder/directory where you have saved the above-downloaded files. If you are a Linux or Mac user, then launch a terminal app on your PC
  • Enter the following command in the command prompt to check everything is working properly. Once you enter the command, you should see the serial number of the phone, if not then you might have to install all the drivers for your phone

fastboot devices

  • Type in the following command to flash the stock recovery

fastboot flash recovery recovery.img

  • Now execute the below command and then follow the on-screen prompts. This step will erase all data of your phone

fastboot oem lock

  • Your phone will be in an endless bootloop when it reboots. Don't worry, as this is quite normal
  • Boot the phone into recovery mode by holding the Power and Volume Down buttons together
  • Choose English as language
  • From the main recovery menu, choose the option that says Upgrade via sideload, so that the phone will get into ADB sideload mode

Type adb sideload ota.zip

  • The sideload will take some time, after which you need to reboot the phone. Just select Reboot and then press the Power button to confirm the process

You phone will now boot into stock OxygenOS 3.2.1 firmware. The above method has been shared by folks over the OnePlus forum. After you execute fastboot one lock command, all data of your phone will get deleted and then reboot. The phone might get into bootloop, with the phone's screen going completely dark. If that happens, hold the Power button until it reboots. Or, just hold Power and Volume Down together for rebooting.