How to Restore Moto G 2014 to Stock and Lock the Bootloader

276

Following the great success of the original Moto G, the best-seller for Motorola, the company has now released the 2nd generation of the phone. The Moto G is known for offering outstanding features and performance at incredible price and this factor is the greatest reason behind its success.

The new Moto G brings exciting improvements over its predecessor and sports a 5.0-inch (720 x 1280) HD display, 1GB RAM, 1.2 GHz Qualcomm Snapdragon 400 Quad-core processor, microSD slot, 8MP primary and 2MP secondary camera and 2070 mAh battery. The phone comes with the latest Android 4.4.4 out of the box.

The Moto G 2014 is already available and if you have already got hold of it, bookmark this tutorial for future reference. Today, we’ll give a detailed guide about how you can restore Moto G 2014 to stock firmware and lock its bootloader in case you have already unlocked it. Suppose you have a rooted Moto G and you have also installed a custom recovery, you might get into a situation at some point of time when you’ll have to flash the official firmware to recover your phone. By installing the stock firmware, you can unroot your device and return to stock recovery.

Disclaimer

The method described below has been tested. However, we do not hold any responsibility for a happy ending in all cases. Just follow the guide carefully and at your own risk.

Getting Prepared

  • Download the 2nd Gen. Moto G (XT1063 / XT1064 / XT1068 / XT1069) firmware from here or here.
  • Download mini fastboot kit:  mfastboot-v2.zip  |  mirror
  • Download and install Motorola USB Drivers (alternate link) your computer.
  • Enable USB Debugging on your Moto G 2014: go to Settings> About and tab Build version 7 times to unlock Developer options. The go to Settings> Developer options and enable USB Debugging.
  • Backup your apps and data as flashing the firmware would wipe them all. Use these apps backup your data.
  • Last but not the least, charge your phone to ensure at least 70% battery.

Restore Moto G 2014 to Stock

  1. Download the firmware file and extract it to a folder.
  2. Extract mfastboot-v2.zip and copy its content to the same folder where the extracted firmware files exist.
  3. Reboot your Moto G into the Bootloader Mode. You can do it using either of the methods given below:
    • Turn off your phone and then press and hold the Volume Down + Power buttons simultaneously for a few seconds.
    • Connect your Moto G to computer using the USB cable. Open the firmware folder where you have copied the mfastboot files. Launch a command window, type the following command and press the Enter key:
      adb reboot-bootloader
  4. Now here is how to flash the stock firmware. Make sure the device is connected via USB cable and launch a command window from inside the firmware folder and type the following commands one by one:
    mfastboot oem lock begin
    mfastboot flash partition gpt.bin
    mfastboot flash motoboot motoboot.img
    mfastboot flash logo logo.bin
    mfastboot flash boot boot.img
    mfastboot flash recovery recovery.img
    mfastboot flash system system.img_sparsechunk.0
    mfastboot flash system system.img_sparsechunk.1
    mfastboot flash system system.img_sparsechunk.2
    mfastboot flash system system.img_sparsechunk.3
    mfastboot flash modem NON-HLOS.bin
    mfastboot erase modemst1 
    mfastboot erase modemst2 
    mfastboot flash fsg fsg.mbn
    mfastboot erase cache 
    mfastboot erase userdata
  5. If you own the Indian Moto G 2014 XT1068, try the following command instead:
    mfastboot.exe oem lock begin
    mfastboot flash logo logo.bin
    mfastboot flash boot boot.img
    mfastboot flash recovery recovery.img
    mfastboot flash system system.img_sparsechunk.0
    mfastboot flash system system.img_sparsechunk.1
    mfastboot flash system system.img_sparsechunk.2
    mfastboot flash system system.img_sparsechunk.3
    mfastboot flash modem NON-HLOS.bin
    mfastboot erase modemst1 
    mfastboot erase modemst2 
    mfastboot flash fsg fsg.mbn
    mfastboot erase cache 
    mfastboot erase userdata
    mfastboot oem lock
    mfastboot reboot
  6. If you also want to lock your phone’s bootloader, type the following command and hit the Enter key:
    mfastboot oem lock
  7. Finally, reboot your device by typing:
    mfastboot reboot
  8. You Moto G will reboot now but if it is unable to pass the boot screen, try this: turn off the device, go to Bootloader mode, launch command window wipe cacahe and userdata by issuing these commands:
    mfastboot erase cache 
    mfastboot erase userdata
    
    mfastboot reboot
  9. To relock the bootloader on your Moto G 2014, type the following command and hit the Enter key:
    mfastboot oem lock

Wait till your phone boots up. Done! You have successfully restored your Moto G 2014 to stock!

  • prasanna kumar

    while i am trying above commands with ur stockrom it shwing remote failure

  • prasanna kumar

    what was the commands we have to give

  • frank white

    hi rakesh so is there a way to root s7 Sprint yet

  • Is your phone carrier-branded?

  • David Wilkes

    Hi I followed the guide and all looked good but on reboot it stops at the ‘warning bootloader unlocked’ screen and goes no further. i have checked and when going back into fastboot it shows that it is locked!
    help
    btw its an XT1032 i have tried the vodaphone rom and the retail one

  • reflashing with correct command doesnt help to solve the problem pls help.

  • NorK

    hello i tried to flash my moto g xt 1068 but it failed.dislaying this msg on my phone screen:
    – USB Transferring….
    -USB Transmission OK Time:1ms Vel:32768KB/s
    – Not Supported’Partition’.
    And then it crashed displaying this message on screen.I tried to reboot the phone but unsuccessfully.

  • Uday

    Same thing happened for me now…What is the solution??? It’s completely dead :((….If you have any solution please mail me at udaydm7@gmail.com

  • david blancas

    Thaks you peter!!!!!!!! it works so perfect to me!! 🙂

  • PdeWitte

    It works with marshmallow. Keep in mind that you enter commands for all the sparsechunk.*, otherwise the flash won’t work

  • Milind Singh Bisht

    Hey. Will this work on Marshmallow as well? I really hope it does 😀 😐

  • Abhay Kumar

    i did same as u said, now presently my phone is unlocked, and back
    camra is not working please tell me the solution. I am not accecpting
    update as people have got problem while updating. what shoud i do so
    that my phone will get the shape again and i can update my phone to
    latest firmware safely. please tell me the solution friend. thnx in
    advance

  • Abhay Kumar

    i did same as rajat said, now presently my phone is unlocked, and back camra is not working please tell me the solution. I am not accecpting update as people have got problem while updating. what shoud i do so that my phone will get the shape again and i can update my phone to latest firmware safely. please tell me the solution friend. thnx in advance

  • Vineet

    Thanks!
    Just so you know and just so many users don’t brick their precious phones that in my case (5.0.2), there are 5 img_sparsechunk files in the firmware folder (0,1,2,3,4). That is, after this command ‘mfastboot flash system system.img_sparsechunk.3’, add ‘mfastboot flash system system.img_sparsechunk.4.’ if applicable. Check the firmware folder first!

  • Naga Nallavan

    thanks it works great!
    but after i install kitkat i update lollipop officially after that my phone won’t start up… my mobile was dead help me!!!!!!

  • Vineet

    Hi. Just so you know and just so many users don’t brick their precious phones that in my case (5.0.2), there are 5 sparsechunk files in the firmware folder. That is, after this command ‘mfastboot flash system system.img_sparsechunk.3’, add ‘mfastboot flash system system.img_sparsechunk.4.’ if applicable. Check the firmware folder first!

  • juop

    i have the xt1072 model. is it also working for this? my Problem is that i dont have either an os, so i cant start my phone. i just have twrp on my ohone

  • Varun

    I updated a kitkat.. but When i installed a Ota my phone wont turn on.. My moto g2 was dead :/ Can u tell me the solution for this

  • Shashank More

    MY both sim slots works again!!!!……..thank u very very very much………..U r really owesome!!!

  • Thanks for sharing!

  • Nishanth Nanchari

    I have installed TWRP recovery on my moto g2 XT1068. by doing this process will it get back to stock recovery..?????

  • Rajat Jacob

    Nevermind… I got it

  • Rajat Jacob

    Found the solution…. Scroll Up!!

  • Rajat Jacob

    Found a solution…. scroll up

  • Rajat Jacob

    Found it… Scroll up

  • Rajat Jacob

    I found the solution… Scroll up to the discussion

  • Rajat Jacob

    thank u so much.!! could you pls add a link for dual SIM?? thank you in advance!

  • It’s for the single SIM variant..

  • Reflash the firmware again using the correct commands for youe device model.

  • Rajat Jacob

    Is this post for Single SIM or Dual SIM?? I have a Dual SIM phone and I flashed this. So please tell me

  • Rajat Jacob

    Is this post for Single SIM or Dual SIM?? I have a Dual SIM phone and I flashed this. So please tell me

  • Rajat Jacob

    so many ppl have the same problem… me too… can you pleease tell us how to fix it??

  • Rajat Jacob

    so many ppl have the same problem… me too… can someone please tell us how to fix it… or at least what the problem is…

  • Rajat Jacob

    your device is not connected properly or is not in the bootloader

  • Rajat Jacob

    By mistake, I followed the instructions for Global devices, but I have an Indian device. Now both my SIM slots are inactive. I tried reflashing a custom ROM, still inactive, I factory reset it, its still inactive.

    Please tell me how to fix it.
    or at least how to unflash/deflash partition gpt.bin

  • Rajat Jacob

    Download a Custom Boot Logo.
    Download it then,
    fastboot flash logo .bin
    then, instead of the warning, the logo will show.

  • Rajat Jacob

    Most Custom ROMs are region independent. CyanogenMod works perfectly with all Indian Networks and SIM cards… (till I tried relocking my bootloader, now my SIM Cards don’t work!)

  • Rajat Jacob

    I got the same thing… Did you follow the instructions for Indian or Global devices??? Do you have an Indian or Global device??

  • Sahil Dhull

    Ruud van Leeuwen!!!!! maan u rock….. worked for me

  • Pingback: Install and Root Soak Build of Android Marshmallow on Moto G 2014 (XT1068) | DroidViews()

  • aman

    when i write mfastboot oem lock begin on the command window i found what is the problem ?

  • Dheeraj Singh

    did u get any solution

  • Dheeraj Singh

    even i have the same problem…!!!!!

  • Dheeraj Singh

    and i am unable to relock bootloader…

  • Dheeraj Singh

    both sim networks are not cmng…what should i do?kitkat 4.4.4

  • Kanishk Chaudhary

    bro im facing the same problem, did u solve it? anyone pls help me!!!

  • sudheer kumar kapatralla

    Hi Admin
    I tried to edit camera settings by following your steps for Rooted Moto g2 xt1068 wtih TW recovery.
    As u said i edited the system .prop txt file .
    It did’nt worked for me so I replaced the file which i backed up and over written it.
    After this process my mobile stuck in Boot loop.
    It is just flashing on moto boot page.
    I can open recovery and tried all the steps by clearing cache i did’nt wrkd.
    Unfortunately I did’nt backed up my previous stock rom.

    Can u suggest me how get out of this problem.

  • Mark John Magallanes

    After flashing it, I can’t get pass the setup stage. It says “Unfortunately, setup has stopped.” and I don’t know what to do next. Tried reflashing it several times but no luck

  • Pedro França

    After unlocked to restore original ROM 4.4.4 (after OTA) update, i cannot lock my device again, is it normal?

  • joker sheikh (YsoSerious)

    Bro I have same problem of no sim network plz….Help me how did you do it plzzz MOHD plz….

  • joker sheikh (YsoSerious)

    Did you find any solution for no sim network bro. ..I to got the same problem….

  • cheri

    thanks for posting your comment..! i would not have known what was wrong if you hadn’t.

  • Redoy Hasan

    sometimes i can see my sim contacts

  • Redoy Hasan

    hi Rakesh after updaate my network has gon error no sim card or no service.Please help me my networks are gone i cant use my sim..what to do??

  • Om Chunamari

    Yes, You will receive all updates released by Motorola in future.

  • Ganga tejeswara Varma

    can send down link

  • Ganga tejeswara Varma

    i have unlock the moto g2 can i relock is by andriod kitkat 4.4.4

  • Ganga tejeswara Varma

    hi

  • Sultan Lav Shah

    Hello. +Rakesh Shukla If I will flash this ROM on my moto g 2014 XT1068 will my device be able to receive OTA Updates rolled out by motorola.!??

  • Ryuk

    no it does not work that way , ratchet is right we need to run sdk for windows to recognise adb

  • Anil (Ministry of Home Affairs

    yes i have solved this problem. download custom rom KIKKAT version now you can the your problem is solved done. and after solve your problem please don’t update your phone because if you update your phone your phone will be dead. thanks

  • Shoaeb

    Please help me rakesh

  • Shoaeb

    Please help me my networks are gone i cant use my sim..what to do??

  • Marinos Ioannoy

    hi everyone i have 2 problems

    1) i have the moto g 2 gen 1068 and i don’t know what firmware to download …. can anyone help me ???

    2) I’ve tried before to lock the boot loader and i lost the system image this method will restore it ?

    please answer to me

  • Benjamin Flores Copa

    Thanks a lot, it works =)

  • Benjamin Flores Copa

    Did you solve this problem?

  • Srini T

    Hi Rakesh,

    I installed blisspop rom in to my moto g2, but I getting smiler issues with that can you pls help out from. Need to reset my original settings but I tried this all but no luck. If you have any video about it pls send me to my mail id (cinivas.t@gmail.com) so that i am really happy with that.

    Thanks
    Srini T
    9396962624

  • Anil (Ministry of Home Affairs

    i have lost my IMEI Number, when i type *#06# so msg is show (IMEI: Null) on the both SIM so please tell me how can i restore. please help me.

  • Prasun Parihar

    Hi there. I have tried the above process and installed the stock rom on my phone. But the bootloadoer is still unlocked. Can you please tell me the process to rellock it……????

  • shivam

    Plzz tell the whole process don’t have that my knowledge on software flashing

  • Try this command: mfastboot oem lock

  • You’re welcome!

  • shivam

    Rakesh i am using stock kitkat on my moto g2 i want to lock the bootloader what i have to do plzzz help

  • Ram sai

    Hi everyone, I’m posting here for your help. A few hours ago I flashed my cellphone to install GPE rom at the first time it seemed that it had worked but then I noticed that it got stuck in the google screen after this I tried to install it again and then I noticed that in the instalation process these error showed up “hab check failed for boot” and “hab check failed for recovery” and the phone got stucked in the boot image. I tried almost everything to make it work but sadly nothing worked for me. therefore, I’m asking you if you could help me, does anybody know how to fix this?? please I don’t want a brick on my night table . I hope you can help me and thank you very much !!.

  • karthik

    i have a doubt while doing….
    should i do that 4 and 5 step or any one

  • Hari

    Thank You! It really worked!! Awesome Sir, thank you!!!

  • The firmwares we tried had just four files. In some firmware, it might be 5.

  • Russ

    there are 5 system.img_sparsechunk. instuctions is missing the final piece

  • Fábio Oliveira S. Júnior

    For the love of God! Help me, I did the whole process on my Moto G XT1069 2014, and when I start, it enters the boot screen where you have the options (Recovery, Factory) and emabixo says so (failed to validate system image) please help me resolve the error in rom also stock

  • siva

    same thing happens to me also..1day back

  • Prasun Parihar

    I have done all the things successfully and configured the rom also. But, after the full setup, only black screen comes and notification panel is not working properly. System apps are also not installing……..

  • Ibrahim Dal

    Hello,
    How can i find my region rom ?

    My region is INDIA but can’t find it supported rom ?
    Any idea ?
    Thanks for help …

  • disqus_aAVYqJIqfA

    How to take away the motorola advertisment (booloader unlock) ??

    I have an error when i try : ”

    mfastboot oem lock”

    thanks man

  • Abhigyan Singh

    Tried but still no option for back camera

  • Perform a data factory reset.

  • Abhigyan Singh

    there is no option for it tooo

  • Abhigyan Singh

    bro help after downgrading i am not able to switch cameras its s
    tuck on front cmaera

  • Ali Abdallah

    I have an xt1064 that’s in a boot loop and doesn’t have any charge in it (does it charge when it’s in the bootloader menu?)

  • Is your device getting device by ADB?

  • benjamin

    Rakesh please help me…
    i have the xt1068, i wanted relock the bootloader and when i flashing my moto g it not found :'( it says “failed to validate system image” please help me u.u excuse my bad english, im using a translate haha

  • I have the same problem! Any update on this?? 🙂

  • Just open the mfastboot folder and issue “adb reboot bootloader” command. It will work.

  • Ratchet

    I understand that you dont need the SDK, but for the folders to appear eith the adb executable and msfastboot I needed to run the SDK first for those folders to appear, plus the 1st command line (adb reboot boot-bootloader) you need windows to recognise adb before hand. Hence you need to add it to the system variables, or else you will only get an error stating that its not a known command on the terminal. You probably overlooked it, but for future reference I would advise you to add a link on how to do that so for anyone else that has no idea what to do can have some information.
    Thanks anyway.

  • It’s because you need not setup the Android SDK. Using the mfastboot is enough

  • Ratchet

    You did not mention that you have to set adb as a system variable so the executable is recognised to be able to run any commands in the first place, and platform-tools and tools only show up after running the SDK.

  • Did you even try check things before drawing your fantastic conclusion? The tutorial uses minimal ADB and Fastboot tools.

    Besides, ADB and Fastboot files are included in the Android SDK by default. You only need to navigate to the “platform-tools” folder.

    2 eye-opener screenshots have been attached below. Between, blaming is the easiest thing to do.

  • Ratchet

    Poorly done tutorial, you don’t take account that adb.exe is not included in the android sdk download nor do you explain how to get it. 4/10

  • If you have ADB working for one device, it does not make a case for it working for all other devices. “waiting for device” means ADB is not detecting your device. Do you have USB Debugging enabled on the phone?

  • John

    it wont recognize my g2 but it recognizes my smartwatch so it cannot be a driver related issue (I have tried removing my smartwatch)

  • It’s a driver related issue.

  • John

    I have left my phone on standby for the last few days and I could use my touchscreen for one session which I used to allow debugging after doing this I booted into bootloader and I tried to run the command again and it just says waiting for device and my fastboot and adb work fine

  • You toggle between front and rear cameras in Camera settings.

  • Abhigyan Singh

    plzzzzzz help i got to kitkat but now the icon for switching the camera has gone
    it is stuck on front camera

  • Viral Rana

    hi how u did please share me step by step i also have same version and i m stuck somewhere.

    please help

  • I don’t think ADB will work without Debugging enabled.

  • John

    I noticed that the USB debugging wasn’t connected with my pc the only problem is I can’t give it access as my touchscreen is broken on my phone so is there some way I can bypass this that you know of

  • Then the problem might be with the ADB and Fastboot drivers. The best way to know if everything is fine is to connect your phone to computer when it’s turned on and type this command (without quotes) in the cmd: “adb devices”

  • John

    I keep getting device not found and I know that my usb drivers work because my device shows up when I connect while it’s powered on please help

  • mohd

    I DID IT….now all is well.thanks

  • mohd

    hello.i am from india. i mistakely wipe system files (all), i unlocked bootloader of my moto g2 (2014). now i flashed RETAILDSDSALL_XT1068_5.0.2_LXB22.99-16_cid7_CFC with above steps. . and now my moto g2 is in ON condition but there is no network in both sims. 1 slot is saying “emergency calls only” and another 1 is saying “no service”. please help me 1thing also now my moto g2 syatem version is 21.11.14. please help me as soon as possible

  • Pranav Banga

    thanx for ur interest in my prob. i had now flashed brazilian lollipop update with custom recovery

  • Hey, what you are encountering is the connectivity issue. I already suggested what to do. Try some other computer.

  • Pranav Banga

    anyone here???

  • Pranav Banga

    reply please

  • Pranav Banga

    now its giving error “adbwinapi.dll is missing”…now i downloaded this dll and pasted it….downloaded a different firmware also…..still having error”waiting for device”

  • Victor Grimaldo

    Thanks, the sound is very poor in that version of CM 🙁

  • Yes, you can install the firmware the manual way as described above.

  • Victor Grimaldo

    I’ve got the bootloader unlocked and installed TWRP 2.8.6.0-titan to flash Cyanogenmod version cm-12-2015-01-31-UNOFFICIAL-titan, I didn’t update the bootloader, can i flash this firmware? can I flash it with TWRP or I need to run every command? Kind regards!!

  • Pranav Banga

    ok giving…

  • Show me screenshot of the folder where you have placed the firmware files and also of the command window.

  • Pranav Banga

    plzz help….i tried everything…and when im writing ad reboot-bootloader, its showing that adb is not recognized as an external command!!!and after next command its showing’waiting for device’

  • Pranav Banga

    now im trying to manually install android lollipop on my device with twrp recovery….hope it works, and not brick my device!!!

  • Pranav Banga

    im still not able to do dis…..
    i want to die -_-

  • I still say it’s connectivity issue and there could be many reasons why you are facing it.

  • Pranav Banga

    its still saying…waiting for device.
    i changed usb cables….reinstall moto usb drivers

  • Pranav Banga

    thnx…i will do the same…n pst the result to you

  • It’s a connectivity issue. Reinstall the USB drivers, try a different USB cable and port, reboot your computer and make sure USB Debugging is enabled on the device.

  • Pranav Banga

    help plzz!!!

  • Pranav Banga

    AFTER I TYPED THE VERY FIRST COMMAND, ITS SHOWING ME “WAITING FOR DEVICE”.
    AND I AM NOT ABLE TO WRITE THE NEXT COMMAND….ANY HELP WOULD BE APPRECIATED!!!THANK YOU

  • No.

  • Abhigyan Singh

    Does this require a unlock bootloader

  • Shubham Jain

    How to root my xt1068 and i m a beginner plz provide a link

  • Yes. Restore the stock firmware and re-lock the bootloader.

  • Shubham Jain

    my phone warranty can be restored or not?

  • Nikith

    my mobile is totally hanged what to do..?

  • Nikith

    the same codes will be applicable for moto E..? by downloading motoe firmware please reply for me na @fixziadmin:disqus in twitter or here…!!

  • Nikith

    @fixziadmin:disqus thank you very much for helping me out you are really great

  • Fixzi Admin

    Any Changes in Mfastboot commands i have to make bcoz this is the image of lollipop 5.0.2 INDIA

  • Indian firmware have 5 system images.

  • Try this for the Indian version:

    mfastboot.exe oem lock begin

    mfastboot.exe flash logo logo.bin
    mfastboot.exe flash boot boot.img
    mfastboot.exe flash recovery recovery.img
    mfastboot.exe flash system system.img_sparsechunk.0
    mfastboot.exe flash system system.img_sparsechunk.1
    mfastboot.exe flash system system.img_sparsechunk.2
    mfastboot.exe flash system system.img_sparsechunk.3
    mfastboot.exe flash modem NON-HLOS.bin
    mfastboot.exe erase modemst1
    mfastboot.exe erase modemst2
    mfastboot.exe flash fsg fsg.mbn
    mfastboot.exe erase cache
    mfastboot.exe erase userdata

    mfastboot.exe oem lock

  • Fixzi Admin

    Can You Tell How Many System Image in This 5.0.2 lollipop Android OS Of XT1068 [INDIA]

  • Fixzi Admin

    Disable Your Anti Virus And Then Download…

  • Fixzi Admin

    @Christian de la Cruz :- Its True When Unlock your Bootloader your warranty is “VOID” , But after Flashing your Phone ….. Re-Installing Android OS & Locking your Bootloader will turn your Status form 0 to Status 2. It Indicates you have Unlocked your Phone & Again you Re-LockedIt .

  • Fixzi Admin

    After Following all the steps mentioned My Moto G 2nd Gen xt1068, it Shows an Error Message:- Failed to boot(this happened when i executed the command to lock my bootloader/oem). Now My phone shows Bootloader unlock message and starts to fastboot mode …… when i try to do it agin from the 1st step my device is unable to be detected [error: device not found] i tried step 7 also… help me to restore my phone to stock mode and lock bootloader.

  • Yes.

  • Allen

    After flashing stock rom, will we get ota updates?

  • Chinni. Sai

    already i have tried this one also but system shows “failed to validate system image”.it’s not able to boot

  • Chinni. Sai

    actually i was unlocked my boot loader,again by using you r provided oem lock cmd ,lock the bootloader after locking my bootloader i am not able to open my mobile,once iam traying to open it shows msg “failed to validate system image”

  • Anurag Dixit

    U’ve to unlock it again. only one line fastboot/mfastboot code, i.e. fastboot oem unlock followed by unique code of ur device. Thats it.

    This’ll unlock ur device and will be able to boot.
    I too faced the same prob, but that’s how I resolved..

  • Anurag Dixit

    U’ve to unlock it again. only one line fastboot/mfastboot code, i.e. fastboot oem unlock followed by unique code of ur device. Thats it.

    This’ll unlock ur device and will be able to boot.
    I too faced the same prob, but that’s how I resolved.

  • What’s your actual issue- locking the bootloader or is it caught in a bootloop?

  • Chinni. Sai

    It shows a pop up msg “failed to validate system image”.

  • Chinni. Sai

    hmm,after wt i have to do?

  • Chinni. Sai

    yes i restored but what is the problem i dont know,my mobile is not working plz help me

  • Anurag Dixit

    Unlock It Again, Only Run This Line, Nothing Else.

    fastboot oem unlock

  • Have you restored the firmware on the device successfully?

  • Chinni. Sai

    plz help me sir,after using this oem lock command my phone is not working.

  • Chinni. Sai

    plz help me sir

  • Chinni. Sai

    plz help me sir,my mobile was not switched on

  • Chinni. Sai

    I have used this command,then system shows oem locked after few min it shows failed to validate system image please tell me wt i have to do?

  • @DroidViews:disqus, will I recover the guarantee if I lock the bootloader? Some people say that instead going to status 0 (locked), locking again causes an status 2 (locked again) in the stock recovery.

    I wanna recovery my guarantee. Is this the correct procedure?

    Regards.

  • Emiliano Musacco

    I got a bootloop trying to install CyanogenMod 12 in my xt1063. if i follow this process will work with my droid? will be in kitkat 4.4.4 stock?

  • Pingback: [GUIDA] Moto G 2014 - Permessi di Root e Custom Recovery (TWRP) - Modding Motorola Moto G 2014 - P8 - Androidiani()

  • If you have download “mfastboot-v2.zip”, it is safe to use. I used it today.

  • Anhaltiner

    my antivire says – pishing

  • What do you mean?

  • Anhaltiner

    mfastboot software is pished!

  • Yes, use this command: mfastboot.exe oem lock

  • Chinni. Sai

    hi,
    i was unlocked my boot loader nd downgrade to kitkat. it is possible to re-lock my moto g(2nd gen) bootloader? plz give me a suggistion

  • Ibrahim Dal

    (bootloader) Please flash valid signed images firstly!

    I am getting this error, what that problem ?

  • Yes.

  • 3rtzu

    will this method remove twrp recovery?

  • tnpravin

    Sir im getting error Device not found plz help me sir urgent i reed to unroot &RE-lock boot loader of my moto g2 xt1068

  • peter

    Open up Device Manager on Windows and Uninstall the Motorola Driver and just re-install it bro. Also don’t forget about using the proper USB Cable because that might be another issue you may be encountering. Also If your doing this through Linux / Mac OS X it will not work I’ve tested it on both and it does’t work.

  • peter

    Here’s my tip of advice : Give More Description, Adding Videos are nice too, and don’t forget one thing because you guys forgot to add

    mfastboot.exe flash system system.img_sparsechunk.0
    mfastboot.exe flash system system.img_sparsechunk.1
    mfastboot.exe flash system system.img_sparsechunk.2
    mfastboot.exe flash system system.img_sparsechunk.3

    in between

    mfastboot.exe flash recovery recovery.img

    and

    mfastboot.exe flash modem NON-HLOS.bin

  • peter

    <3 you too

  • levi

    I love you peter you saved me money and my phone!!!!!!!!!!! like you dont understand the extent im happy to man i gave up on my phone after flashing the stock firmware and it being stuck in a boot loop but saved my life!

  • savinay jalan

    thanks bro u r a life saver

  • You are still making mistake. Looks like I won’t be able to help you.

  • savinay jalan

    what to do rakesh

  • savinay jalan

    what to do

  • savinay jalan

    C:UserssavvyDesktoprestore>adb reboot-bootloader
    ‘adb’ is not recognized as an internal or external command,
    operable program or batch file.

  • savinay jalan

    it is also showing that adb is not recognized as an internal command

  • savinay jalan

    it is still showing waiting for device

  • savinay jalan

    K THANKS

  • Copy the rom file in the ext. sd card, insert it in the device and flash the rom. It wil be fixed.

  • savinay jalan

    and another thing that when will lollipop release for rooted motog2s

  • savinay jalan

    can u plz plz plz plz plz plz look for my mobile’s problem.

  • savinay jalan

    talk 2 u 2morrow

  • savinay jalan

    it is showing in teamwin that there is no OS installed on your device

  • savinay jalan

    in clearing the userdata and cache and dalvik cache my mobile’s OS got deleted

  • savinay jalan

    nop 8

  • savinay jalan

    canu u plz give me the solution r else my mum will give my phone in the service centre

  • How did the device get into bootloop if you did not do anything at all? Are you using Win 8.1?

  • savinay jalan

    can yo plz give me a soltion for that.

  • savinay jalan

    and my mobile has also gone into a boot loop i think so cause its not sarting up

  • savinay jalan

    waiting for device

  • savinay jalan
  • savinay jalan

    it is just showing and i have done everything correctly

  • That points to USB drivers issue. Also, where did you launch the cmd window from?

    To check proper drivers installation, connect the device to computer, make sure to allow debugging on the device, launch cmd window and type “adb devices” and hit enter key.

  • dhaval

    every time they are sating device is waiting when i start , i install all the driver though that
    error is comming what to do
    please help

  • ankit sharma

    if i have to unlock the bootloader again ,do i have to do the some thing which i did before like getting the moto id and unlock code and doing that again ???

  • Mason Crump

    I reinstalled them but its still saying waiting for device

  • rishabh kakkar

    help me out i followed the steps carefully but now my phone is not starting it is just showing the “warning bootloader unlocked” screen and nothing else is happening

  • Reinstall the USB drivers.

  • Mason Crump

    it keeps saying “waiting for device”

  • At what points do you think are the steps wrong. We would like to know of our errors, to improvise.

  • peter

    To Start of with this tutorial was horribly done this is the proper steps you need to use in order to flash the software properly + have the bootloader locked

    In the command prompt enter this…

    mfastboot.exe oem lock begin
    mfastboot.exe flash partition gpt.bin
    mfastboot.exe flash motoboot motoboot.img
    mfastboot.exe flash logo logo.bin
    mfastboot.exe flash boot boot.img
    mfastboot.exe flash recovery recovery.img
    mfastboot.exe flash system system.img_sparsechunk.0
    mfastboot.exe flash system system.img_sparsechunk.1
    mfastboot.exe flash system system.img_sparsechunk.2
    mfastboot.exe flash system system.img_sparsechunk.3
    mfastboot.exe flash modem NON-HLOS.bin
    mfastboot.exe erase modemst1
    mfastboot.exe erase modemst2
    mfastboot.exe flash fsg fsg.mbn
    mfastboot.exe erase cache
    mfastboot.exe erase userdata
    mfastboot.exe oem lock
    mfastboot.exe reboot

    When your phone reboots don’t worry if your boot screen says bootloader unlocked everything is working fine and your bootloader is unlocked just flash the logo too

    fastboot flash logo logo.bin

    AND BAM WOLAH

  • Yes you can, Go ahead and flash.

  • rohi ananthula

    hey my device is XT-1068 KXB21.85.23 and there is no firmware available for this so can i use RETLA_XT1068_KXB21.85.24

  • rohi ananthula

    is this firmware supports my device

  • Have you tried the firmware i provided?
    And read step #7.

  • rohi ananthula

    hey what to do my mobile cant pass the warning bootloader unlocked page after this above process

  • Try this firmware: http://d-h.st/VOw

  • rohi ananthula

    hey i cant find my device firmware XT-1068 KXB21.85-23 plsssss……help meee

  • Hi Mike, you are right but many Moto G firmwares have just 3 system images.

    P.S. see this: http://forum.xda-developers.com/showpost.php?p=57649861&postcount=1

  • Paulo Freire

    I made the question wrong, but thanks. I solved my problem.

  • mike

    This wont work because there are 4 system images – system.img_sparsechunk.0 system.img_sparsechunk.1 system.img_sparsechunk.2 system.img_sparsechunk.3. If you dont flash all of them, it won’t boot and it will be stuck at the bootloader. Please fix this guide.

  • What do you mean by ‘block”?

  • Paulo Freire

    My bootloader still block. What to do?

  • % krishna %

    thank you works fine

  • % krishna %

    the link for firmware dosnt work please update it

  • Sai Ram

    the link for firmware is down .can you please provide another link ASAP

  • Inderpal Singh

    Hab check failed for boot

  • Inderpal Singh

    Is this problem solved? I am facing same issue

  • nagendra

    why the bootloader is not showing as locked though used the command?could you help me to lock bootloader.

  • Babidi

    The http://sbf.droid-developers.org/phone.php?device=36 website is down. So if anyone needs the XT1063 firmware you can get it from here:

    http://180upload.com/bzl3ah1wov5g

  • Tell me what error?

  • Kevin Arthur

    i got an error when i enter the code to unlock.
    =/

  • Avoid that mess right now. Go ahead, lock the bootloader and try the procedure again. It has come to me in a bit shock that the steps are giving an error.

  • Kevin Arthur

    my bootloader is unlocked. i dont understand about the uploading of the bootloader?? how cna i know what version it is ?

  • A shot in the dark, have you updated your bootloader to Android 4.4? Secondly, is your bootloader locked or unlocked?

  • Kevin Arthur

    i used them. This is maybe because i got my bootloader unlocked? or

  • After doing a little research, I found out that it is an issue related to fastboot binaries. Try using these fastboot files: https://docs.google.com/file/d/0B4PT9WP-u_z9NXRBWF9EV2lGcWs/edit

  • Kevin Arthur

    i tried and tried my friend, also i tried to flash the boot part but nothing. same error. =/

  • It seems like you corrupted your recovery partition while trying to flash it. And hence, the Android bot warning logo shows up. Try and flash the recovery partition again in fastboot mode using the following command:

    mfastboot.exe flash recovery recovery.img

  • Kevin Arthur

    hello, i have a XT1063 so when i flash the boot and the recovery i receive a purple message. “hab check failed for recovery” hab check failed for boot” . After that the phone turns on normally, but when i try to update by OTA and try to enter to the recovery it shows the image of a dead android. Help pls!

  • Yes if it is present, it should be flashed.

    Wait, I also see that you’re getting an unlocked bootloader message. Try this and see if it boots again, then you might even need to restore to stock: http://www.droidviews.com/remove-unlocked-bootloader-warning-moto-g-2014/

  • Madhavan krishnan

    my model is moto g 2014 (Indian)dual sim and i am flashing with “RETAILDSDSALL_XT1068_4.4.4_KXB21.85-14_cid7_CFC_SVC.xml” file.
    i had a rooted and unlocked bootloader with TWRP installed .
    i first didnt notice this error and went on with the process later when my phone didnt boot .i realized that this error is there .now my phones screen is flashing ever 4 sec the unlocked bootloader message untill my battery goes off..
    thanks replying in short notice

  • Its the only way to unlock. Try reloading the Motorola website again.

  • chotu

    i had try the motorola web site not working

  • chotu

    kk

  • chotu

    in boot loader it shows device is locked, how to unlock plz help

  • chotu

    android sdk

  • What are you using, minimal fastboot or Android SDK?

  • chotu

    plz help me
    im unable to root my moto g xt 1033
    mistakely i locked boot loader, i dnt know how to unlock

  • chotu

    not working

  • Execute “fastboot oem unlock” command.

  • chotu

    i had already unlocked boot loader and again locked how to unlock boot loader

  • chotu

    i locked the boot loader how to unlock

  • Do you have your bootloader unlocked already?

  • Madhavan krishnan

    on giving comand:
    flash partition gpt.bin

    “target max-sparse-size: 256MB
    sending ‘partition’ (32 KB)…
    OKAY [ 0.063s]
    writing ‘partition’…
    (bootloader) Preflash validation failed
    FAILED (remote failure)”

    Pls help me out

  • Use this command: mfastboot.exe oem lock

    or “fastboot oem lock” if you are using Android SDK.

  • iamwholesquare plus

    So. what about locking the bootloader?

  • 🙂

  • Leif Bragisson

    my bootloader was locked :/
    I unlockeed it and everything worked. thanks for your help

  • Have you downloaded the appropriate firmware file?

  • Leif Bragisson

    yes. booting, rebooting, unlocking bootloader… evertything works fine, except for flashing the images…

  • Flash it again. Can you see your phone’s IMEI by dialling *#06# ?

    Also make sure to install the correct firmware.

  • Do other adb and fastboot commands execute fine?

  • Leif Bragisson

    every time I type a command, the answer from the command promt is “fail”
    then i rebooted and it was restored, but didn’t install the factory image…
    can someone help me?

  • Pingback: Install Android 5.0 Lollipop OTA Zip on Moto G 2014 XT1063 & XT1064()

  • Abdul Majid Farooqi

    please help me,,,after flashing the firmware my sim networks is disabled, what should I do now?

  • You can use ‘fastboot oem relock” for that.

  • Tech Feelings

    but you can change the boot logo. I did on my motorolla no more message about unlocked bootloader 😀

  • Tech Feelings

    true

  • Matthew Goddard

    No I mean that it will not relock the boot loader.

  • Tech Feelings

    That need to be done from motorolla site.

  • Matthew Goddard

    yes but the bootloader will not lock

  • Tech Feelings

    Correction
    When you download above firmware there are four ‘system.img_sparsechunk’
    instead of 3. So continue as following and it will work otherwise one part is missed and you can’t go beyond boot logo

    mfastboot.exe flash system system.img_sparsechunk.0
    mfastboot.exe flash system system.img_sparsechunk.1
    mfastboot.exe flash system system.img_sparsechunk.2

    mfastboot.exe flash system system.img_sparsechunk.3

  • Tech Feelings

    Correction
    When you download above firmware there are four ‘system.img_sparsechunk’
    instead of 3. So continue as following and it will work

    mfastboot.exe flash system system.img_sparsechunk.0
    mfastboot.exe flash system system.img_sparsechunk.1
    mfastboot.exe flash system system.img_sparsechunk.2

    mfastboot.exe flash system system.img_sparsechunk.3

  • Dhamukanna

    I have X1068 Moto G 2014 with unlocked bootloader.. I followed the above mentioned steps but got bootloop. I tried erasing cache and user data but when I reboot bootloader unlocked warning message comes but cannot boot into system. This goes as a loop continuously.. Please help