How to restore my iPhone to remove jailbreak and then unlock it?

I want to remove the jailbreak from my iPhone by restoring it however it isn't unlocked to 3 so if I do it, it will ask for a sim which I don't have. Is there a way to restore it then unlock it to 3 without jailbreaking it?
It is a iPhone 3GS by the way.

Added (1). Ffs just went on my phone and its stuck on the apple boot logo, the power button don't work so i can't turn it on or off and its not being recognised by itunes!

Instructions

1
Plug your iPhone into your computer using the connector cable that came with the phone. ITunes launches. Select the iPhone under "Devices" in the left navigation panel of iTunes. Click the "Restore" button found in the main iTunes window under the "Summary" tab.

2
Read a brief warning and click "Restore."

3
During the restore process, you are asked whether you want to back up your iPhone. When iTunes backs up your iPhone, it only backs up non-jailbreak specific information such as your contacts and photos. If you want to keep all your data, agree to the back up.

4
The iPhone restarts and you are prompted to choose between restoring from backup or setting up the device as a new iPhone. Follow the onscreen prompts.

5
Disconnect the iPhone from the computer when the process is complete.

6
Go into your Photos app on the iPhone and select "Camera Roll." If there are any photos of Jailbreak apps, delete them so there's no evidence of jailbreaking.

Just update via itunes and then go here: http://gsmunlocklabs.com/unlock-iphone/

  • Would backing up then restoring an iphone remove a jailbreak? Due to the recent release of IOS 7, i plan on updating my iphone 5(ios 6.1.2) but it is jailbroken. Would backing up then restoring my iphone keep all my pictures and app data while removing the jailbreak? If not what is your best recommendation for me to do. Would really appreciate an answer thanks!
  • Jailbreak then restore iPhone 5? Is it possible to jailbreak my iPhone 5, install app locker- lockdown pro then restore it & keep the said app? Really want an app to lock individual apps on my phone, invariably people get there hands on your phone & in this scenario I want my private stuff to remain private. Not jus speaking of pics, I already hav that app. I mean for things like mail, txt, memos, notes. Don't want to jailbreak my phone if there's an alternative.
  • IPhone screen shows Apple icon then shuts off, then repeats I was updating my software on the iphone when the power went off, then the screen went black and showed the apple icon, then it shus off again, then it shows the apple icon. I plugged it into the computer but they computer does not recogniz it so I can't restore it. What do I do?
  • If You JailBreak Your IPhone and then restore it, does your warranty return? I recently jailbroke my IPhone but then got scared, I then re-stored. Now my lock button does not work and I have to get it repaired. I'm afraid that apple will recognize that I have jailbroken my IPhone and then not repair it. So when I restore my phone does the warranty still stand?