Easily reset the HTC One M8 UNLOCKED status to LOCKED

The HTC One M8 comes with locked bootloader, you can see it on the bootloader mode (turn off the phone, then press and hold Vol down + Power), it should say *** LOCKED *** at the top. However, this status will change to UNLOCKED along with tampered once you unlock the bootloader via HTCDev or gain S-OFF with Firewater. We believe this is one of the efforts made by HTC to reduce the interest of users to unlock their smartphones. Furthermore, most likely your device will be rejected when you claim the warranty.


Fortunately, there is a developer from xda – scotty1223 – who expose a method to reset the HTC One M8 bootloader from UNLOCKED to LOCKED again with simple adb command line. The best thing is, to get this done, we don’t need a token from the HTCDev or submitting our phone’s personal information to HTC. According to the dev, this method should work on several variants, including Verizon, Sprint, AT&T, T-Mobile, etc.

Actually, there is an easy command to lock the bootloader after you unlock it, simply by running “fastboot oem lock” command, sadly this command has a small success rate, and has a possibility to fail. In addition, this command will only change the UNLOCKED status to RELOCKED not LOCKED.

  • HTC One M8, S-OFF’ed with Firewater.
  • Get the updated HTC USB drivers, without HTC Sync.
  • A Windows, Mac or Linux computer. However, this guide made for Windows PC.
  • Setup adb on your computer.
  • Enable USB debugging
htc one m8 reset unlocked status

Image: HTC / @evleaks

Reset the HTC One M8 UNLOCKED status to LOCKED

  1. Get into a folder where you save the adb files.
  2. From there, hold shift and hit mouse right-click then choose “Open command window here” option.
  3. Perform the following command to check if adb has worked well:
    adb devices

    It should show your phone serial number.

  4. Here is the command line you should run, one at a time, re-type, do not copy paste:
    adb shell
    echo -ne ‘\x00\x00\x00\x00’ | dd of=/dev/block/mmcblk0p2 bs=1 seek=33796
  5. Now verify that your HTC One M8 status has changed to LOCKED, boot into bootloader mode:
    adb reboot bootloader



Filled Under:Unroot and Relock
Related Mods

8 Responses

  1. Jeff
    May 2, 2014 at 4:01 AMReply

    It’s not working to reboot bootloader and says locked still! Any ideas????

    • Author

      Robbie S.
      May 2, 2014 at 4:24 AMReply

      Are you S-OFF? Copy paste the command?
      Try to manually type it, especially for the echo command, since WordPress changes the character, or go to the dev thread on xda (source link).

  2. Bob
    May 7, 2014 at 10:36 AMReply

    If you copy/paste the echo command above, it won’t work unless you change the single quotes from curly to straight.

    • Author

      Robbie S.
      May 9, 2014 at 4:24 AMReply

      Yes, you’re right, wordpress change it automatically. I hate that.

  3. Justin
    June 3, 2014 at 2:52 PMReply

    So this will reset the bar to LOCKED, but will it also re-lock the bootloader?

  4. Priyansh Gupta
    February 2, 2015 at 7:56 PMReply

    Tried it number of times….. But doesn’t work

  5. Joser
    March 5, 2015 at 11:29 AMReply

    After it relocked my phone won’t boot up, goes straight to bootloader!! Help pls

  6. lewis
    September 16, 2016 at 6:24 PMReply

    says permission denied when i write in the long code, i tried copy and paste and writing it normally.

Leave a Reply