Fix iTunes Error During iPhone Restore (via Hosts file)

Fix iTunes Restore Error

Fix iTunes restore Error By Editing Hosts File – It is common issue to be faced with iTunes Restore error while restoring iOS firmware on your iDevices (iPhone, iPod Touch, iPad). We’ve covered some of them as below:

[+] Fix “An Unknown Error Occurred (1)” while Downgrading iOS 4.3.4
[+] Fix iTunes Restore Error Code Restore Error 3002, 1604, 1600

Fix iTunes Restore Error

However somehow you’ll also might be faced with another kind of iTunes error which prevents you to restore your iPhone’s (or other idevices but here we’ll use “iPhone”) firmware.

Amazingly, this iTunes error can be fixed by simply editing “hosts” file. But how can we know if this is the type of iTunes error that can be fixed by editing hosts file?

Simply conduct a ping to Apple server at “ping” and if you’ve found or see something other than, then you’ll need to edit hosts file.

ping Apple server

On Windows

Start Menu >> Run >> type ping >> click [Ok]

On Mac OS X

Open Terminal >> Type ping >> hit Enter

How to Edit Hosts File to Fix iTunes Error

Step 1 – Open Hosts File:

On Mac: Press COMMAND + SHIFT + G on keyboard >> go to /private/etc/ >> find and open Hosts file >> edit it with text editor
On Windows: Press Windows Logo + E keys to pen Explorer >> go to C:\WINDOWS\system32\drivers\etc >> right-click host file >> open with NotePad

Step 2 – Add following line:

hosts file

Step 3 – Now save the file and flush DNS Cache to make it work:

On Mac : open Terminal >> type dscacheutil -flushcache >> hit enter
On Windows : Start Menu >> Run >> type ipconfig /flushdns >> click [Ok]

That is it. Now try again restoring your iPhone via iTunes and you should not facing any issue.


Thanks for reading articles on You can get updates quicker via email. Subscribe freely below.

5 Responses

  1. Derek CheungAugust 6, 2011 at 4:47 amReply

    the ipaddress didn’t work….the links in that site didn’t work.

  2. GuilhermeOctober 21, 2011 at 1:43 pmReply

    I tried this but when I hit *SAVE* my mac says I can’t save the file… seems I have “READ ONLY” permission .. and even after putting READ AND WRITE, it won’t be saved in the folder, somewhat like a system folder it seems, that won’t let me save any change in there… clue?

    • Larry DingalberryNovember 17, 2012 at 9:38 pmReply

      it also works if you just delete the apple host # without adding a new one.

  3. michaelNovember 29, 2011 at 8:15 amReply

    didnt work. ive tried redsn0w, itunes (with and without host edit) (with felix official and custom (piratebay) (shift-click) firmware, tried rejailbreaking and cydia install with greengas, in dfu and recovery mode, and even tried pinging that to get the number and just got bunch of request timeouts. even flushed. f**k it.

  4. RichFebruary 22, 2012 at 3:57 pmReply

    didn’t work for me either, phone stuck in recovery mode

Leave a Reply