Even though Android is better performed when rooted, still there are situations we have to unroot and restore the default firmware such as the warranty issues. Unroot a device means, lose the root access, remove the custom recovery and restore all the other customizations done on the OS level. So if you are a Nexus 5 user and looking forward to unroot and restore the stock android on the device, follow this guide carefully. Remember all the data from the device will be erased so make sure to take the full backup before proceed.

This is the stock copy of the Android which comes with the factory default settings and for the Nexus 5 ‘hammerhead’ only. Read all the steps carefully before you proceed with the unrooting. This method can also use to recover the device from the Bricked state.



  • Take backup of all the important data.
  • Make sure the device have minimum 70%-80 battery backup to avoid unexpected power off.
  • Install the USB drivers of Nexus 5 to connect the phone to your PC.
  • Enable the USB debugging mode. To do this Go to Settings -> Developer Options -> and enable the option USB debugging. If you can’t see the Developer Options, Go to Settings -> About Device and tap seven times on the Build Number of the device.

Unlock the Bootloader of Nexus 5

You have to unlock the Nexus 5 Bootloader to apply the stock ROM. So if you haven’t unlock it already, follow the steps to do the same.

  • Connect your Nexus 5 to your computer using the USB cable.
  • Go to the folder where Android SDK is installed and open the folder named platform-tools.
  • Launch a command prompt by holding Shift key and clicking anywhere in the opened screen, then choose the option ‘Open command window here‘.
  • Once the window is opened enter the command; ‘fastboot oem unlock
  • The process will take some time and once it’s finished the device will wipe clean.
  • Disconnect the device from PC.

Unroot/Unbrick and Restore Stock Android on Nexus 5

Step 1: Download and extract the latest Stock ROM file of Nexus 5 from here. The file will be in .tgz format.
Step 2: Switch off and boot the device to Fastboot mode. To do this, press and hold ‘volume up, volume down and power’ buttons simultaneously.
Step 3: Connect the device to the PC using the USB cable.
Step 4: Go to the folder where the downloaded files are extracted and run the file ‘flash-all.bat’. If you are using Linux or Mac, then run ‘flash-all.sh’. Then wait for the process to complete.
Step 5: Once the process is completed, go to the Fastboot screen on your device and select Recovery. Then press the power button to boot the device in Recovery mode.
Step 6: From the Recovery screen select the option ‘wipe data/factory reset’ and confirm.
Step 7: Choose the reboot option from the Recovery home screen.
Step 8: Wait until your Nexus 5 is started in Normal mode with the Android stock firmware. Now you can unplug the USB cable from the device.

That’s it! You have a stock ROM installed Nexus 5 now. If you face any problem during the process let us know in the comments section.