1: Connect the device to your computer and open iTunes.
2: If the device appears in iTunes, select and click Restore on the Summary pane.
3: If the device doesn't appear in iTunes, try using the steps in this article to force the device into recovery mode.
iPhone User Guide