Note: The process should work nearly the same on Windows and OS X, so unless we say otherwise, you can follow the same steps on each. The main difference between Windows and OS X is RecBoot, so Windows users, make sure you pay close attention to the RecBoot process before diving in. The same basic steps should likely work for iPhone 3GS, according to our 3GS-toting intern Adam Dachis, who’s used a similar method in the past. Lastly, you should read through the entire guide before you dive in, just so you know what you’re getting into.
Step 1: Find or Download iOS 3.1.3 and RecBoot
The first thing you need to do is get a copy of the iPhone OS 3.1.3 image. There’s a good chance you’ve already got a backed up copy of the 3.1.3 release on your system, so let’s check there first. On OS X, check in ~/Library/iTunes/iPhone Software Updates. On Windows, your iPhone OS updates should be stored in C:\Documents and Settings\[username]\Application Data\Apple Computer\iTunes\iPhone Software Updates (or to get there more quickly, type Win+R and paste %appdata%\Apple Computer\iTunes\iPhone Software Updates). If you see a file inside this folder corresponding to iPhone1,1_3.1.3_7E18_Restore.ipsw or iPhone1,2_3.1.3_7E18_Restore.ipsw, those are likely the restore images you need. If you don’t see anything that resembles the 3.1.3 OS or you just want to download a fresh version for good measure, web site iClarified has maintained a list of iPhone firmware files. Just find 3.1.3 for your phone (the 3G version points here and it’s what I used successfully) and download the 228MB file. Next, download RecBoot from here (available for Windows and Mac). This handy little utility plays an important role in finishing off the downgrade.
Step 2: Put Your Phone Into DFU Mode
You need to put your iPhone into Device Firmware Update (or DFU) mode in order to downgrade to 3.1.3. The video above demonstrates the process, but in case you prefer a little text: Plug in your iPhone. Power it down by holding the sleep/lock button and sliding to power off. Once it’s powered down, press and hold both the sleep/lock button and the home button for ten seconds. After ten seconds, release the power button but continue holding down the home button. If you did it right, iTunes will pop up a window (like the one below) telling you that it’s detected an iPhone in recovery mode and your iPhone’s screen will be black. If it didn’t work, start from the beginning and try again.
Step 3: Restore iOS 3.1.3
Now that you’ve done all the legwork, it’s downgrading time. You can either follow the video above or follow along with the instructions below. Dismiss the iTunes alert that told you you’re in recovery mode, make sure you’ve clicked the iPhone under the Devices sidebar in iTunes, then hold Shift and click the Restore button (if you’re on OS X, Alt/Opt+Click). iTunes will pop up a window prompting you to choose a file. You want to navigate to the 3.1.3 OS you located or downloaded above. Select that file, and iTunes will start the OS restore process. Expect this to take around 10 minutes or so. When it’s finished, you’ll likely receive an error message like the one above (error 1015) and your iPhone will boot up with a “Connect to iTunes” screen. This is where the utility you downloaded above, RecBoot, comes in handy. Open RecBoot, and click Exit Recovery Mode. In a few seconds, RecBoot should kick you out of plug-me-into-iTunes recovery mode and you’ll boot right into your freshly downgraded 3.1.3. Note: I used RecBoot in OS X, and from what I’ve read, the Windows version may have some peculiarities. First, you’ll need .NET 4.0. Second, you may need to run the application in Compatibility mode if you’re not running Windows XP (Right-click the EXE -> Properties -> Compatibility -> Run this program in compatibility mode for Windows XP). You’ll also need to download libusb, which may also be peculiar on 64-bit systems. Read up on using RecBoot on Windows here.
Step 4: Restore Your Backup
At this point, you’ve got a fresh 3.1.3 installation, but you probably want to sync your apps and data back to your phone as they were before you downgraded. If you’re lucky, you’ve got a backup saved from before you upgraded to 4.0 (you can select different backups from the drop-down menu). If you don’t have a pre-4.0 backup, you’re unfortunately out of luck—iTunes won’t let you restore data from a 4.0 backup to your downgraded 3.1.3. This method worked like a charm for us, but your mileage may vary. If you had a different experience, can offer more insight to the Windows downgrade process (particularly with RecBoot), or know of a better downgrade method.