How to install the Android L developer preview on Nexus 5 and Nexus 7

New Android Logo

Google has just released the developer preview images of Android L for the Nexus 5 and Nexus 7 (2013), triggering a reaction from many clueless Android lovers on how they could install it on their device.

Since these preview images are essentially factory images, you need to flash them using ADB/Fastboot. Follow the steps below to find out how. 

Since this is a developer preview, users are bound to run into some stability issues and bugs occasionally. This is strictly for developers to test and build apps in advance for Android L and is not meant to be used as a daily driver.

Flashing a factory image also require users to unlock the bootloader of their device, which in turn wipes its internal memory clean of all data. So, make sure to create a backup before you proceed to the steps below.

Step 1: Download all the files linked below and extract their contents inside a new folder called “android” on your desktop. To make it clear, all the files must be inside the same directory (android here) and not inside any other folder.

android

Step 2: Open up a new Terminal or Command Prompt window and use the ‘cd’ command to navigate to the “android” folder created in previous step on your desktop.

Eg code below in case you are not well versed with the ‘cd’ command:

cd USERNAME/desktop/android

Step 3: Switch off your Nexus 5 and Nexus 7 and reboot them into bootloader mode using the key combination mentioned below

  • Nexus 5: Volume Up + Volume Down + Power
  • Nexus 7: Volume Down + Power

Step 4: Before flashing the factory image, you need to make sure that your Nexus device is being detected by the PC.

fastboot devices

If you are using a Mac, then you need to prefix a “./” before every Fastboot command. So, the above command will look something like this on a Mac -:

./fastboot devices

The above command should confirm if your device is indeed being detected by your PC or not. If it is, then proceed to the steps below. If not, repeat the above steps again. Make sure to check that you have properly installed the drivers and are inside the correct folder.

Step 5: Unlock the bootloader of your Nexus device by executing the below command.

fastboot oem unlock

Make sure to confirm the selection on your Nexus 5 or 7 by pressing the Volume up button. Once the bootloader has been unlocked, proceed to the next step.

Step 5: If you are running Windows, copy-paste the following command in the Terminal/command prompt window -:

flash-all.bat

On a Mac, copy-paste the following command -:

./flash-all.sh

The script will then automatically flash the full factory image on your Nexus device after which it will automatically reboot. Keep in mind that the first boot is going to take an extremely long time, so be patient and don’t start panicking,  thinking you have bricked the device.

If the flash-all.sh script gives you a fastboot not found error on your Mac, open up the file in Text Edit and add a “./” before every fastboot command.

If you want to flash back to Android 4.4 KitKat, follow this guide.

 

Like this post? Share it!
  • smith

    where is flash-all.bat ?

    • not-dumb-unlike-smith

      dumbass

      • Brian Utne

        That username though, hahahahaha.

      • pro0

        Shut up and help!

        • not-dumb-unlike-smith

          DUMBASS

    • Rajesh

      Extract the files from the factory image.

  • Josh Meade

    can i flash this using clockworkmod?

    • bcsc

      Just don’t. You may want to avoid this is that is a legitimate question. The instructions on the ONLY way are directly above.

  • Liam

    how to do step 2 in terminal???????????? Im getting this -bash: cd: Liam/desktop/android: No such file or directory

    • new

      its not actually android, you need to find your platform-tools folder..and according to you have to map it..

    • Rajesh

      Did you create that android folder on your desktop I mentioned in Step 1?

    • Mattnm Atkinson

      i have the same problem, and i followed the instructions please help!!

      • Rajesh

        Where did you create the “android” folder?

        Try cd desktop and then cd android.

        • Mattnm Atkinson

          The folder is on my desktop

          • Rajesh

            Is the “cd desktop” command working for you?

          • Mattnm Atkinson

            No, for some reason no CD commands are working

          • Rajesh

            Umm very strange. I am clueless here. Try another PC perhaps?

  • Skin

    flash-all.bat is not recognized?!

    • rabbit

      Me either!

    • Rajesh

      Don’t double click on the file. Navigate to it via command prompt.

  • Guest

    doesn’t seem that the nexus 5 android L image is a zip file. it’s .tgz. I usually don’t consider myself a complete idiot, so is there something i’m doing wrong?

    • not-dumb-unlike-smith

      you can still extract the files using win-rar

      (smith is a dumbass)

  • Socker

    Please help! flash-all.bat command doesnt work! I’m dumbass but help!

    • truth

      If you can’t figure it out, just use the wugs fresh toolkit. Select flash stock/unroot> other/browse then select the .tgz file you download from the Google website. It will ask you to confirm the md5 sum then it will decompress and flash it for you. I normally wouldn’t recommend any toolkit, but wugs fresh is a really good toolkit, I use it sometimes when I’m feeling lazy. Note they this will obviously wipe your data, and your boot loader needs to be unlocked.

    • Bad_Attitude

      Android sdk installed? Bootloader unlocked? Drivers installed properly? If all above is yes the easiest way to do this would be to open up the folder that has “fastboot.exe” inside of it and shift-right-clilck, choose “Open command window here” then type fastboot devices, hit enter. You should see an alphanumeric device id if it’s working. ALL of the contents extracted for the L image have to be inside the folder with fastboot.exe. Double left-click the flash-all.bat and it should start installing. If you are NOT already familiar with adb/fastboot you DO NOT want to do this. You’ve been warned! ;)

    • Rajesh

      Are you double-clicking on the flash-all.bat file or navigating to it via the command prompt?

  • hi there

    Use 7zip to extract the .tgz, then extract the .tar inside, there will be a folder, inside that folder, surprises await.

    • Thank you!

      Thank you very much! You are good person. I like you very much! Have a nice summer!

  • james

    I keep getting fkash-all.bat is not recognized as an internal or external command, operable program or batch file.

    • Rajesh

      Its “flash-all.bat”.

      • james

        that was just a typo. And i sorted it out now turns out i didn’t have adb installed as i thought. :)

  • Nate Sotomayor

    Someone please help me! When I type “flash-all” my Nexus 7 turns off, then back on into the bootloader. I get the following messages in the command prompt.

    “archive does not contain ‘boot.sig’

    archive does not contain ‘recovery.sig’

    failed to allocate 704979448 bytes

    error: update package missing system.img

    press any key to exit…”

    • Rajesh

      Did you extract all the files? The “system.img” file is missing. Re-extract.

      • Nate Sotomayor

        I have extracted everything. I re-downloaded the files from Google as well. I still get the same error

    • Nexu713

      did u manage to solve the problem? im also having the same issue…

      • Nate Sotomayor

        Yes, but it lead to a new one. My device never booted.

        • Nexus713

          how did u pass the part where it says error: update package missing system.img?
          i’ve re downloaded the file from google multiple of times and keep on getting the same error. am i extracting the file incorrect. first, i’ll open the tgz with 7zip. then double click on the .tar file. It will then give me a folder. i’ll extract that folder.

          • Nate Sotomayor

            It worked for me after I downloaded a new fastboot.exe.

          • Nexu713

            ill give that a go :).. will let u know shortly… did u manage to get ur device to boot up?

          • Nate Sotomayor

            No,unfortunately. I did manage to get into the bootloader after some time. I’m trying to flash 4.4 again, but even this is having trouble

          • Nexus713

            sorry to hear your trouble, hope that will be sorted out soon

          • Nate Sotomayor

            Me too… I’m running out of options. I don’t want to buy a new one (even though prices are coming down) because I want to save for a Moto 360 :D But still I hope I can save it

          • Nexus713

            by the way, where did u get a new fastboot.zip file?

        • Shrawan

          having the same problem. phone is stuck at the google logo :/ what do you think is the problem?

          • Nate Sotomayor

            I don’t know. Currently my tablet is just sitting there useless. I haven’t had the patience to try again haha

          • Lord_Santa

            If you’re having this problem, extract everything from “image-hammerhead-lpv79.zip”.

            Then manually flash each image file using the instructions here: http://forum.xda-developers.com/google-nexus-5/general/tutorial-how-to-flash-factory-image-t2513701.

            After flashing the image files then enter recovery mode and wipe data/factory reset. Reboot your phone and it should work :)

  • Jos Spencer

    No offense, but I’m against guides like this, because so many “stupid” people have problems and then annoy everyone else, “flash-all.bat isn’t recognized”, well if you aren’t smart enough to fix that should u really be doing this to your phone…..

    • مهند

      How would be smart if you have no experience and you never tried it before?

  • Ashish Dewan

    there is no need of unlocking boot loader in 4.4.3,update then why in this one?? will u please tell me,. i am in this field :p

    • truth

      This is a developer build. It is not an official update, it is still in beta.

    • Joshua Dempsey

      You will have to wait at least a few months for this to be an OTA update. You have to unlock the bootloader as this is a developer preview, meant to be used by developers for testing their new applications with the new APIs

      Hope this helps

  • usamaisawake

    I’ve flashed successfully but it doesn’t look like the Nexus 7 2013 32GB wants to boot. It’s stuck on the new boot animation (4 dots representing Google colors flying around each other). I’ve tried going back into recovery and deleting data, deleting cache, but that has not helped, it refuses to boot. I’ve also re-flashed the L preview release, but still no luck. — EDIT: I guess I’m inpatient. It took longer but did boot up. Maybe it was switching over to ART.

  • Joshua Dempsey

    How long did it take people to flash it onto Nexus 5? Becoming slightly worried at the length of time this is taking (about 30 min now)

    • Bad_Attitude

      Woops! It’s never taken me anywhere close to that amount of time to flash a factory image.

      • Joshua Dempsey

        No matter, I found out I was doing it wrong (first time), fixed it now :D Thanks for replying..

        • Shrawan

          i had the same problem. it was stuck at the boot screen for a long time. what do you think is the problem?

          • Joshua Dempsey

            Sorry it took me ages to reply. Have you fixed the problem yet?

          • http://www.facebook.com/antoine.lord.50 Tonylicious

            After flashing my device my N5 restarted and it is now stuck on the Google logo (with a little lock at the bottom of the screen).

            Do you know how to fix this ?

            Thanks!

          • Joshua Dempsey

            Yes I do tony. Turn your phone off, then hold power down and up, then at the same time power it on. Just wait and you will see activity “downloading” etc… the flashing has begun

          • http://www.facebook.com/antoine.lord.50 Tonylicious

            Thanks!

            But in fact, my problem was something else but I fixed it successfully.

            Here’s how I fixed my problem:

            1. I booted in fastboot mode (“adb reboot bootloader”)

            2. I locked my phone again (“fastboot oem lock”)

            3. I unlocked it to wipe everything once again (“fastboot oem unlock”)

            4. I flashed my phone (“./flash-all.sh”)

            5. BINGO!

  • jose

    Can android L be rooted?

    • Rajesh

      Yes, it can be.

  • josh

    Where can I find the flashall file that’s supposed to be in the platform tools folder? I have everything else in there. It never let me extra anything from the preview I downloaded. It is some file that has no way of being used.

    • Rajesh

      Did you extract the contents of the factory image file to the Android folder? The flash-all file is in the factory image. Also, copy/paste the fastboot/ADB files inside the platform-tools folder to the Android folder. *all* the files must be present in the same directory.

  • Noname

    what about nexus 7 wifi 2012 , can it use android l image of nexus 7 wifi 2013 ?

    • Ian

      Nope Sorry

  • Nexus713

    who else is getting this error????

    “archive does not contain ‘boot.sig’

    archive does not contain ‘recovery.sig’

    failed to allocate 704979448 bytes

    error: update package missing system.img

    press any key to exit…”

    • Shrawan

      yeah. and then after booting, the phone is stuck on the google logo :/

      • Tommi Carr

        Same! I need help quick!

    • http://www.facebook.com/antoine.lord.50 Tonylicious

      I have exactly the same problem. Did you find a solution?

      • Rajesh

        Make sure that there is a system.img file located in the same folder as the ADB/Fastboot files.

        • http://www.facebook.com/antoine.lord.50 Tonylicious

          Thank you for your answer but I finally successfully installed Android L ! It was not related to the system.img file.

  • krash

    I tried and got
    failed to allocate 699970328 bytes
    error : update package missing system.img

  • edj809

    I have this issue

    “archive does not contain ‘boot.sig’

    archive does not contain ‘recovery.sig’

    failed to allocate 704979448 bytes

    error: update package missing system.img

    • Akshay

      I’m also getting this error.

      I’m on windows XP. Is this anything to do with Windows XP??

      Anyone has got solution for this??

    • Akshay

      Update: This is windows RAM issue… Not available enough memory on computer. I have not tried yet.

  • Shrawan Sapre

    I followed all the steps.Flashed it properly. However, phone is stuck on boot screen for the past half an hour. Tried re-flashing also. Nothing seems to work. What is the problem?

  • Twan

    It stays on the new loading screen, please help!