Quick Tip: Downgrading 4.0 beta to 3.1.3

So you upgraded to the iPhone 4.0 beta and possibly like me you quickly came to regret it because some of your favorite applications just aren’t working right (for me it was Reeder and Evernote). Well, how do you go about the process of getting back to 3.1.3? Well, it’s pretty simple actually. Here’s what I did and what may help you as well.

First, put your iPhone into DFU mode. At this point if you’ve done it properly iTunes will start bouncing in your dock and complaining about finding an iPhone in Restore mode and it can’t be used until you restore it. So, do that. Click restore and the iPhone 3.1.3 firmware will be put onto the phone. But, just when you think all is well, you’re going to get a nasty 1055 error stating that the firmware couldn’t be restored. Don’t worry. This is normal.

Now, you could go through the hassle of going back to 3.1.2 using the keys on Saurik’s server (you have stored your keys there right?)… then using a jailbreak to get back to 3.1.3 but there’s a much easier way. Go to iHackintosh and download a little utility called iRecovery. Once you have iRecovery downloaded, open up a terminal window and type the following:

cd /directory/to/iRecovery then type iRecovery -s

Wait for iRecovery to load then run the following commands one at a time:

setenv auto-boot true
saveenv
/exit

Reboot your phone by holding the home and power button for about 10 seconds, the phone will then reboot, connect to iTunes and activate.
You’re done!

EDIT: So, here’s another few key steps it looks like you’re going to need if you intend to be able to jailbreak 3.1.3 again. I ended up having to downgrade to 3.1.2 – You HAVE to have saved the ECID file with Saurik. Edit your host file (see details here) to include the following:

74.208.105.171 gs.apple.com

With that in place in the host file and your ECID on Saurik’s server you can safely downgrade to 3.1.2. Once the downgrade was done, I immediately loaded up the Pwnage tool, had it build a custom 3.1.3 IPSW and followed the steps to get into recovery mode. Once 3.1.2 was in recovery mode, I switched back over to iTunes and installed the 3.1.3 IPSW. I’m now back on 3.1.3 fully jailbroken and since 4.0 wasn’t able to backup the iPhone properly – I’m even able to restore the phone from the 3.1.3 backup i took yesterday! Huzzah!

(Don’t forget to return your host file to normal when you’re done with all the IPSW tango).



  • http://intensedebate.com/people/Ragart Thomas

    Thanks for the info, Brandon. Btw Reeder dev has acknowledged this bug and is apparently working on a fix.

    • http://intensedebate.com/people/brandonsteili brandonsteili

      Is there a Twitter account for the Reeder Dev?

  • http://intensedebate.com/profiles/kazemizuhi kazemizuhi

    Not that I need this info myself, but what if one is running Windows and thus as no access to Terminal?

    • ihackalot101

      notepad!!!

  • http://intensedebate.com/people/brandonsteili brandonsteili

    The iRecovery app is universal. There's a Windows binary and a Mac binary. So on Windows you'd just open up a regular command window.

  • Jonnyx69

    Thank you so much you dont know how much i love you right now :D:D

  • regretful

    Is there a way to downgrade back to 3.1.3 non-jailbroken? I didn't jailbreak my iPhone on 3.1.3, but I did install 4.0 and want to go back to the stock 3.1.3. Thanks!

    • http://intensedebate.com/people/brandonsteili brandonsteili

      @regretful – if you follow the first bit of steps I laid out you'll be running a stock 3.1.3 firmware without a jailbreak. Just ignore everything past the "you're done".

  • robat19

    what do I do with iRecovery? I downloaded the file, double clicked it, and it brings up a terminal window saying process complete. I typed to command in terminal after that and it doesn't do anything. Any suggestions?

    • http://intensedebate.com/people/brandonsteili brandonsteili

      Windows or Mac?

      The commands should be the same on either version however. See the comment from adeedew below.

    • Bret

      you don't double click the file. you open up terminal from Applications -> Utilities. Then you type in "cd " followed by the path to the folder you downloaded the file to (e.g. "cd /Users/robat19/Downloads"). then run the commands as per the above instructions

  • USACHRiS

    For the most part this is the long way, with 4.0 beta 1, you can perform a restore using the 3.1.3 image, then when it fails and is stuck on the emergency call, use blackra1n to jail break and then do another restore via itunes. Once it does the restore, you're back to normal (except for the baseband, which is in essence read only at the new level until a new higher level version is out).
    -CHRiS

    • http://intensedebate.com/people/brandonsteili brandonsteili

      I tried this – Blackra1n wouldn't work for me. I tried running it, and it would say complete / wait for reboot. After 20 minutes I got tired of waiting for it to reboot.

      • USACHRIS

        Blackra1n won't finish normally, once the screen turns black, reboot the phone (hold power, or power and home until it does) – once it reboots it will come back and activate (if you have a legit phone to activate on a legit carrier).

  • Dan Lastoria

    Thank you! You're a life-saver. My (non-jailbroken) phone is back to 3.1.3 and everything is running great.

    I'd like to add, that after these steps I was also able to then restore from a previous backup with iTunes and recovered all my personal settings, photos, etc. That might be obvious to most, but thought I'd add that here.

    • http://intensedebate.com/people/brandonsteili brandonsteili

      I did the same thing. Since 4.0 wasn't able to do backups it never got a chance to kill off your 3.1.3 backup.

  • nonomori

    Finally my phone back to 3.1.3. but now comes a problem, after downgrade to 3.1.3, when i restore my phone again, still have 1055 error, even i choose 3.1.3 fireware.

    • http://intensedebate.com/people/brandonsteili brandonsteili

      Just run iRecovery and your phone boot as normal.

  • Xykon

    Just as an added info, you don't need to go into DFU mode if you already have the 3.1.3 firmware downloaded.
    Just keep the ALT key pressed on your keyboard while you click on the recovery button in iTunes and then choose the 3.1.3 firmware to recover.

  • calvin2

    downloaded vmware for windows 7 and got osx snow lep for it

    hooked me iphone up and installed 4.0

    a few apps didnt work so decided to put 3.1.3 back on

    it wont let me put it back on im getting errors 1055, this was through the vmware

    tried it with windows and it wont let me restore it with that, getting error 13

    ive got no software on my iphone at the moment and i need help bad!

    i tried this but it doesnt work on windows or thru vmware http://isource.com/iphone

    help me!

    • http://intensedebate.com/people/brandonsteili brandonsteili

      I'd love to help you – but I don't have a Windows 7 system at all. And I wouldn't try doing anything through VMWare. The software is good, but USB virtualization isn't something I trust all that well. I've see it do some really funky stuff in the past with iPhone restores.

      I all else fails – start the process over. Get your phone into DFU mode and re-install 4.0 – then work your way back to 3.1.3.

    • Brian C

      same problem man….any luck yet??????

  • adeedew

    worked great on a non jailbroken 3gs going back to my restored 3.3.1! Note on a mac the irecovery software after unzipping it just drag it into terminal, then a -s, then cut and paste setenv auto-boot true
    saveenv
    /exit
    and that seemed to work, so far so good, restore from a previous backup

  • sam

    By jove, it worked! Thanks!!!

  • PunkRockTuba

    the above worked fine, dragging iRecovery into terminal then running the commands. My computer would not recognize any command starting with anything but the entire command written out, as in: Users/username/Desktop/irecovery -s. You have to type irecovery exactly how it is, case sensitive. once i got the -s command to go, copying and pasting: setenv auto-boot true
    saveenv
    /exit

    worked like a charm.

    I rebooted my phone manually, it gave me another error, then it rebooted itself and started restoring from the backup I chose.

    this works great, thanks for the

  • m6silver

    never got it to work in windows 7. keep getting no iphone found but run great on a mac. just extract out the "irecovery" onto your desktop. open terminal type "cd desktop" then "./irecovery -s" follow by "setenv auto-boot true" , "saveenv" and "/exit" without the quote. Thanks You Brandom. If not my non-jailbroken 3gs would be dead now.

  • Ryan

    I installed 4.0 on a non-jailbroken iPhone. I decided to downgrade to 3.1.3. I did the shift-click method to install the 3.1.3. firmware (I'm using Windows), and it bricked my phone.

    I followed your instructions – WORKED LIKE A CHARM. My iPhone is restored once more.

    However, my only problem is that it is still running 4.0… even after restoring it and using iRecovery. Am I missing something here?

    • Ryan

      Never mind, I figured it out. My iPhone was in "recovery mode" and I needed to put it in "DFU mode." For the dumb noobs like myself, be sure to read the following link before attempting to downgrade from 4.0 to 3.1.3:
      http://www.ihackintosh.com/2009/06/recovery-mode-

  • Imod Dev

    Hey if i upgrade to 4.0 can i restore my contacts and photos on the 4.0 OS

  • Stephen

    'SETENV AUTO-BOOT TRUE' NOT A DIRECTORY! DOESNT WORK FOR ME PLEASE HELP. I installed the libusb and i did the following. I opened iRestore in Terminal and it ran and then said completed.

    I opened a new terminal. Typed cd Desktop, that worked fine. Typed . / iRestore -s and that worked fine. Then I typed setenv auto-boot true and i keep getting "command not found"

  • polsfuss

    Anybody knows the difference between putting iPhone in DFU or not, before pressing alt + restore to select the firmware from the computer?

  • bubble

    I love OS4, even though it has a few bugs so far. I'm very angry at Evernote who told me they have no intention of fixing their app until after OS4 is released to the public! That is crazy, what the hell do they think a beta is for!?! Would they prefer to risk 100million people being affected and losing half their customers while waiting for Apple to approve their update?? Do they love annoying their biggest fans and evangelisers who are the most common users of OS4???

  • Skyler

    Nice, thanks a lot! Worked like a charm from 4.0 Beta 1 to 3.1.3 non-jailbroken

  • http://intensedebate.com/people/jables2915 jables2915

    i dont understand why there was a need for this all ii did was plug in my iphone put it in dfu mode and hold option click restore, choose 3.1.3 and i was done

    • rich

      where do find the option to select 3.1.3?

  • rob

    This was a tremendous post. I had my phone in dfu mode and it would not go back to 3.1.3 – this post saved me and all is good back in 3.1.3 land. Very happy to have gone back given that many/most apps were struggling to run in 4.0

  • robert

    ive typed the prompt on cmd in windows but the irecovery cannot find my iphone. any solution??

    Thanks

  • enigma

    Hello. I just downgraded from OS 4.0 beta to 3.1.3 with my iPhone 3G. Thank you very much for the great info!!!

  • http://www.facebook.com/ojperez Octavio Perez

    Hey all. I was trying all this terminal business and it wasn't working. I tried using Blackra1n and it worked like a charm. When it says to wait for the phone to reboot, it didn't reboot on its own. I has to reboot it myself. Hope this works!

  • James Dark

    I never saved my ECID file on Sauriks server and now I cant Jailbreak again. Any help?

  • Pingback: Jailbreaking your iPhone 3GS to iOS 4 with Pwnage Tool 4.0 « Just Another iPhone Blog

  • Edwin

    I having a problem here when i run irecovery, I write irecovery -s and my command promt said " got usb but no iphone/ipod found". any idea

    • http://intensedebate.com/people/Ragart Thomas

      you have to specify the path (directory) to iRecovery. I accomplished this by dragging the icon of iRecovery from Finder into the Terminal window. Then I typed -s after that.

      • florian

        i did that but than it tells me reason: image not found … any idea why

  • Dman

    My 3gs simply restored to 4.0 again. Any suggestions?

  • Stephanie

    Is this possible with an itouch? some please help!

  • Sunray39

    Hi,

    I am one of those who regretted upgrading my iPhone 3G from version 3.1.3 to 4.0. Version 4 drastically slows down the performance of my iPhone.

    Now, I managed to put my Iphone into DFU but when I tried to restore it through iTunes, a message from iPHONE `SOFTWARE UPDATE appears and the message reads: iOS 4 Software Update!

    There is nothing there for me to choose version 3.1.3 even after I simultaneously pressed the command key on my Mac Book and clicked RESTORE on iTunes. I certainly do not want iOS 4 to be restored on my iPhone. Could anyone of you there please assist me on this.

    Thanks a zillion!

    HS

    • http://intensedebate.com/people/Ragart Thomas

      try clicking alt-restore instead of cmd-restore.

  • Matthew

    Is there a way to downgrade the software to 3.0?

  • haiteraid

    i have a problem..it says i dont have permission to edit the host file..its locked! tryed to unlock it and the option isnt there

  • Dman

    iRecovery will not open on my pc. Please help

  • Sarah

    Is it jail broken when you do this?

  • florian

    I just jailbroken my phone succesfully, than stupidly wanted to erase all content and now had to go to 4.0 because I could install the 3.1.3 anymore. Could you please give advice, after I got the error in itunes (1604) I went to terminal and did drag and drop with iRecovery. I typed in iRecovery -s but its tells me this: Reason: image not found, Trace/BPT trap. I do hope I still have the OS 4.0 beta.. How do I find out … the system profiler doesn't tell me anything. Thanks for your help …

  • nisa

    hi hello there, i tried downgrading my 3gs 4.0 to 3.1.3 but when the restore button appeared it is with restore and update. so it will restore the phone and update it right away. that way i cant get the 3.1.3 on my phone. please help!

  • AdMok

    Please HELP!
    Last login: Tue Jul 27 23:51:45 on ttys000
    mok-adrs-macbook:~ mokadr$ cd desktop
    mok-adr-macbook:desktop mokadr$ ./iRecovery -s
    -bash: ./iRecovery: Permission denied