Unlock me baby

It's easier to unlock your Nexus 5 bootloader than it is to decide if you want to do it

If you're receiving your shiny new Nexus 5 in the near future, you'll want to think about unlocking the boot loader. It's a bigger undertaking than the folks on the Internet make it out to be, and doing it later is a huge pain in the kiester, so it's worth talking about. 

First things first. Since it's a Nexus device, it was designed to be easily unlocked. There is no extra encryption layer, no signing your life and warranty away at the website of the people who made your phone, and no software hacks to try to bust your way around things. You only need the SDK and be able to use the command line — which are things you need to know about before you ever decide to unlock your phone anyway.

The how is even easier. Turn on USB debugging on your Nexus, plug it in to a computer with a working SDK, and type the following commands:

  • adb reboot-bootloader
  • fastboot oem unlock

Then follow the instructions on your phone's screen. Really. That's it. It will erase everything on your phone, so it's a good idea to do this right away if you ever plan on using it. 

But before you do it, remember a couple things. Unlocking your boot loader makes your phone unsafe. Period. It just does. Think of how easy it is to unlock things. It's equally easy to get all your personal data off of the phone, even with a secure lock screen. Your boot loader is unlocked. The phone will flash any files it is told to flash — including ones used to root and suck everything out of it. There's also the warranty to think about, though Google has been more lenient on that than other OEMS — they say it "may" void your warranty, not it "will" void it. And finally, if you want to use the Nexus in any BYOD plan at work, check with your IT guys and make sure it's OK to do it. They like stuff to be as safe and secure as it can be.

In the end, it can be rewarding and is a crapload of fun, as long as you understand the risks.


Reader comments

How to unlock the Nexus 5 bootloader


If I unlock the boot loader, will I still get system updates (over the air) from Google?

Yes if you are running stock rom with stock recovery. But if you have an unlocked bootloader you can just flash factory images.

Sent from my White Nexus 4.

The main point of unlocking the bootloader is the ability to flash custom recovery and flash custom roms. Once you flash custom roms you likely cannot get OTA updates or they may not install properly even if you get the prompt. If you're concerned about getting OTA updates then you're better off not unlocking your bootloader.

But if you do custom roms, the developers incorporate android OS updates faster than when you get them OTA anyway.

That's not very accurate, at all. Plenty of people unlock the bootloader just to get root access and they never permanently flash a custom recovery or ROM. On a nexus device this option is particularly appealing because it allows you to still take the official OTAs the moment Google sends them out (worst case scenario being losing root and having to reinstall SuperSU to regain it).

Reasons for wanting root access are many and varied but there's tons of apps that require it for advanced functions (Titanium, etc). Point is you don't have to forsake OTAs just because you unlocked the bootloader, that's only the case if you're gonna dive into custom ROMs (which frankly I've found less and less necessary on nexus devices).

Gotta love these questions. If you have to ask this. Do NOT attempt to root your device. You'll have a bad time.

Posted via Android Central App

If I enter a chip from another country will my new nexus work without doing this??

posted from chingaTuMadre EPN

I think he assumed you speak Spanish based on your sig, which is mildly offensive btw (translates to fuck your mother, in case you didn't know). His reply just states that you don't need to do this to swap SIMs, this is just to root, experiment with ROMs etc.

The direct translation isn't very accurate, it's more akin to mofo in English even tho that's kinda backwards... But yeah, a mod might wanna snip it out either way.

Puro pinchi Peña Nieto alaverga!! Tipico pejezombie que ni trabaja y se rebela en twitter pensando que es una macana para la politica. Ponte a trabajar pinchi webon!!

First my signature is to support my friend. And I do work. So if you guys just for a signature deduce so many things. I know now why people hate mexicans

posted from chingaTuMadre EPN

Yeah yeah go to eat some beans or tacos. While I enjoy my Nexus 5 when it arrives...

posted from chingaTuMadre EPN

And if you do unlock and want to be secure again, just flash a stock system and recovery and do fastboot oem lock (a locked phone only stops fastboot from flashing unsigned files, but does nothing to stop the recovery or system from doing so).

So are you saying if you want a custom ROM, you can:

fastboot oem unlock
flash custom recovery
fastboot oem lock

now you can flash custom ROM's while keeping bootloader locked? Interesting. I thought a locked bootloader would refuse to *load* an unsigned kernel image, in addition to preventing you from flashing a custom image.

Thanks Jerry for helping out. There are a lot of people that would like to know this kind of stuff and I'm glad that your taking the time to explain things. I've used your "how to flash nexus 4 factory img" a few times. Great stuff. Nexus FTW

Posted via Nexus 4

I made the mistake of not unlocking my bootloader first when I got my nexus 4, this time around I'll be sure to unlock it before I spend the time setting anything up.

If you want to root your device, you need to unlock the bootloader first.
Head over to the forums for all your answers, they are a great help!

Thanks, Jerry, for your helpful post (as always). After having 2 rooted tablets stolen in a smash and grab robbery, and considering your warnings, I'm seriously rethinking my attitude about unlocking and rooting, and what kinds of data I want to exist on my mobile devices.

Much as I hate to have to do it, I may just give up on the unlocking and rooting of any Androids.

Better to rethink the how and why of what you store in the tablets, if that's what you're concerned about. You can be rooted and still secure sensitive information, tho most thieves are just after the device and couldn't care less about your stuff.

I truly hope they don't care about my personal info, and just want to reset it and sell it for more drugs

Posted via Android Central App

Seeing as there are millions of new android users every year, I would say yes. If you are already all knowing and don't need the info, then just don't click on the article. Pretty simple solution

Posted via Android Central App

Every new Nexus device release is someone's first Nexus or even first Android device, so yeah, it will be new to them. Veterans don't need to bother reading these articles

AT&T doesn't have to know it's unlocked and they don't have to activate anything, you just put the SIM in... Sprint situation (specially with phones sold on contract) might be more complicated but they're usually rather lenient on this matter. I've even sold back rooted devices to Sprint for account credit (S-off bootloader and everything, they don't even check at the store).

Sprint will activate it, you can even do it online but you need to get a sim card (called a UICC) first. They will give you one free but most stores don't have them yet or even have any idea that the phone from the Play store will work.

Friday the corporate owned Sprint stores should have them for sure and hopefully the reps will have had some sort of news release or training so that if you walk into a store and need a sim they will know what to do.

AT&T is not Verizon, they cannot tell nor do they care. Especially if you don't buy the device from AT&T they only care about those things if you break your phone and want to get it repaired or replaced under AT&T warranty. If you don't then they could care less how you mess with your phone hardware, they only care that you use their wireless service

Not turning this into anything but I imagine that you can do the same with a Nexus as you can with any other phone. I am talking soft brick, bootloops, and other nasty things.

Soft bricked and bootlooped my Note 3 two days ago so let me give you a piece of advice.

Don't drink, flash and ROM. Any kind of flash BTW.

Also, have a way to get back handy in case you do..

Posted via Android Central App

It's really not much of an issue with a nexus, just flash the factory image. You have to work pretty hard to permanently screw the software on a nexus.

Posted via Android Central App

Same thing with Samsung, it was just a pain in the azz from where I was doing it. If I would have been home, and sober, it would have been as simple

Posted via Android Central App

I'm pretty sure you can't hard brick a Nexus device, though.

Posted from my pure Google Nexus 4 using the AC app.

Bet you can. kick out the cord once when it is flashing the bootloader.

That is the only time I heard of Samsung getting hard bricked. Everything else has been recoverable to my knowledge

Posted via Android Central App

Ah hell, NoNexus is on another tirade! Samsung screwed a lot of us that had the i9100 and the n7000 with the emmc brick bug. Thanks Samsung!

Posted via Nexus 4

Typically, someone creates a sticky thread with step by step unlocking and rooting instructions (including links to needed files) in the phone's forum. Unfortunately, nobody has done this yet. Anyone want to take on the project? I'm great at following directions, but not so good at creating them.

What exactly does unlocking the bootloader do, why would you want to do this?

Posted via Android Central App

It allows you to flash custom roms and more easily root your phone by simply flashing root rather than having to wait for an exploit to be found that gets around locked phones like on pretty much any other phone.

1. installation of custom recovery like TWRP or clockworkrecovery mod - they are custom software that replaces the factory recovery software which allows you to do neat stuff like wiping data, factory resets, wipe dalvik/cache, create nandroid backup images, and flash custom roms, kernels and other software mods

2. being able to flash custom roms, kernels and other software mods. Doing this also requires rooting as well which is a separate process to be done after unlocking the bootloader.

Essentially unlocking the boot loader let's you flash a custom recovery, which enables you to gain root access if you wanted, and also flash custom ROMs to the phone. You will gain quite a bit more control over your device.

Posted via Android Central App

My god folks still don't know how to do this. So sad, go back to your Idevice you don't deserve a nexus. Stop trying to be cool.

Posted via Android Central App via bad azz VZW LG G2 ROOTED!

You sound like a freaking tool! a lot of people are new to this and dont want to risk messing up their phone. So drop the cocky attitude.

My guess is that it's mutual.

I realized long ago that the power of knowledge is in sharing it with others. This is in contrast to what I call knowledge hoarders. These are people that refuse to share information for fear of losing what they perceive as their power. These folks are particularly nasty human beings.

Absolutely! After all, when you got your first android device you already knew everything about bootloaders, and everyone should be as smart as you!

Boy, the DBs are out in mass today.

Posted via Android Central App

You sound like the one trying to be cool. I love to root/rom/mod, but what's wrong with if the average person doesn't want to do? I guess Nexus devices are only for 1337 hax0rs.

Mine comes today. Too bad all the Sprint stores I have spoken to have no clue about this phone and therefore I will not have the needed SIM or UICC card to activate the damn thing. Thankfully, Sprint online chat is more knowledgeable and was able to send me one but it means a few more days of delays. Argh, I wish I didn't have to be on Sprint for work.

How long are they gonna take to send you one? My Nexus 5 arrives Thursday, maybe I should start procuring it already? I doubt stores in Puerto Rico are gonna have their ducks in a row by Friday but it could just as well take a week for Sprint to get me the SIM by mail if they're being cheap on shipping...

I assume your current phone remains activated until you actually put the UICC to use?

They did not say when they will ship it yet. I don't have a tracking number yet but only ordered about an hour ago. This message keeps getting listed as spam if I include shipping time and cost but overnight is about the same as google charged to ship their phone (13 bucks) or you can choose a slower free method to ship(3-5 days). The SIM card itself also doesn't cost anything.

They don't need the phone information like the MEID to send you the card either. I would try to get one shipped to you. Might be there by the time your phone arrives. Just say you bought a Nexus 5 from Google and you need a SIM card for it and that the stores near you don't have any or aren't knowledgeable about the Nexus 5 and how to activate it if you bought it from Google.

And yes, your current phone remains active. When you get the card you insert it then either call Sprint and activate like normal or do the activation online through your Sprint account.

Edit - I just got the email stating it would ship today.

Nice, thanks for the info buddy. I might swing by the store first to see if they're even remotely aware of what's going on, but if they're not then I'll surely be calling Sprint to have them send me one.

Sweet! Mine is riding around in the back of a UPS truck and is supposed to be here this afternoon. Can't wait.

No, after the bootloader unlock you would then flash a custom recovery and after that you would go into your custom recovery and flash a root zip file. Just beware that replacing your recovery will probably make google updates not work. You would have to flash back to your stock recovery to accept an update. There are also the one click root methods which someone linked above that can do everything for you but I like to know the steps. Just make sure if you do it that you use a recovery designed for the Nexus 5 and not a random recovery you find on the internet.

I'd check out XDA and or the Android Central forums for more information and the correct files. I am sick of the flashing scene lately so I am going to stick with completely stock if I can stand the ads.

There's another option tho... You can BOOT into a custom recovery by going into BOOTLOADER and then using fastboot/adb tools to flash SuperSU, without permanently flashing a custom recovery. Booting is temporary and thus once you restart from recovery, the custom recovery will be gone.

Going thru adb is easier, there's guides for doing this on the Nexus 7 and I imagine process is basically the same (though SuperSU probably needs to be updated for 4.4 for everything to work smoothly).

You basically end up completely stock, only with root. Since you're only adding things rather than modifying then the OTAs should still install without issue. This is what I did with my Nexus 7 since I've never felt like messing with custom ROMs on my tablets... I've always run a custom ROM on my phones tho so dunno if I'll go this route.

OTOH all my phones were HTC/Sense too, and I obviously didn't have a choice but to use an exploit to install a custom recovery and root (well, HTC provided an official method for the EVO LTE but w/e).

I'll probably start off with a stock build on the N5 and go from there. I rather like having the freedom to use root-only apps without forsaking Google's OTAs.

I'm going to have to look into this. On my Nexus 7 that is the exact setup I want but I have been flashing the stock images I download from google without wiping my data, installing a recovery, flashing a zip then reflashing the stock recovery.(or something like that, I always have to look at a guide to know the exact steps) I didn't realize you could simply boot into a recovery temporarily.

Can you use the recovery like a permanent recovery at that point and do things like wipe dalvik cache? I see you said you use fastboot/adb tools to flash SuperSU but couldn't you use the recovery controls to flash a zip if it is on your devices internal memory?

Yes you could (and should, depending on what you're doing) wipe dalvik from a temp booted recovery. Someone also mentioned the CF-Auto-Root script from Chainfire in an earlier reply (same CF who develops SuperSU amongst other things), that does essentially the same thing I was alluding to (at least on a Nexus), just automated. I like following the steps manually too tho...

I've never had trouble with ota with a custom recovery. The trouble comes when you start messing with system files, if you're gonna mess with them, make a backup! When ota time comes I just flash the backed up system partition and am good to go.

Posted via Android Central App

With this being such an unbelievably easy and known process for a Nexus device I can not believe how this has been plastered across the internet. #Weallreadyknow

I see that we have one more person who lacks the mental capcity to understand that Android is growing and for many many people this is their first time with a Nexus or with any Android device and those new people weren't born with knowledge of how to unlock a bootloader encoded into their genetic structure, so instructions are still needed. #theworlddoesntrevolvearoundyou

The easiest way I know of to unlock your bootloader on a Nexus device is with WugFresh's Nexus Root Toolkit (http://forum.xda-developers.com/showthread.php?t=1766475). The toolkit will unlock the bootloader, and/or root your device (with or without installing a custom recovery), install custom ROMs, perform back ups, return to stock, and just about everything else you can think of. I really like it for noobs like me.

I'm surprised the Nexus 5's bootloader is locked! It's a Nexus and they're meant for developing!

StealthDroid - Working in the Nexus Lab

Every Nexus' bootloader has been locked, even the Nexus One's... And I think every successive Nexus has moved further and further away from being a "developer phone", it's no more a dev device now than a MS Surface is.

Regardless, the point about the bootloader has always been that you CAN easily unlock it with a single fastboot command... Not that it's unlocked out of the box.

On other phones it's either not possible without exploits/hacks (because it's encrypted, signed, etc) or you have to go thru a formal process where you register with the manufacturer and basically disclose you're doing it (possibly voiding the warranty etc).

It is another (pretty easy) step. Unlocking the bootloader enables you to get root access.

Just as I said in the the earlier post about using SDK to record the screen. Its filled how do I this, how do I do that!?

Posted via Android Central App

This article is really over stating how insecure unkocing the boot loader is, for one if your paranoid you can encrypt your device. Secondly to even do adb and fastboot commands you need to verify your computer on your phone, which can't be done without unlocking the device. There's no way to extract the password, to do so you need access to adb, and as I mentioned before you'll never get it without verifying the computer first.