Although having an unlocked bootloader is useful in many ways like flashing firmware (factory images), installing TWRP and getting root, but it can also lead to blocked services on your device due to security reasons and hence you you might want to relock bootloader to avail those services.
Earlier today, Google released an update to SafetyNet which now also considers a device’s bootloader unlock status to trigger SafetyNet and disable certain services, like Android Pay.
Thankfully though, relocking bootloader will solve the issue for you. But (of course) you’ll lose all the benefits that comes with having an unlocked bootloader on your device.
The fastboot commands to relock bootloader aren’t same for all devices, so we’ve put together a list of all known Fastboot commands that you can use to relock bootloader on your device in the instructions below.
How to Relock Bootloader via Fastboot
- Setup ADB and Fastboot on your PC.
- Connect your device to the PC, and open a command window on the PC.
- Issue the following command to boot device into bootloader mode:
adb reboot bootloader
- Now issue the following commands (any one) to relock bootloader. You don’t need to use all the commands given below. If any one works, stop there and follow the next step.
fastboot oem lock
fastboot flashing lock
fastboot oem relock
- Once bootloader is locked. Reboot your device with the following command:
That’s all. If you’ve any suggestions to add to this page, let us know in the comments section below.