Well this has gotten way easier. If you have an AT&T iPhone and it is off contract (e.g., two years since you bought it), here is how you get it unlocked so it will work with any carrier (eg T-Mobile or you can use it overseas with a different SIM):
- Apply to AT&T. This can be pretty random calling, but now there is an online way to do it at https://www.att.com/deviceunlock/ and enter your information including the IMEI
- You should get email in a few days (for me 24 hours) that says you can unlock
- You can check that this is true by checking the Apple IMEI database. The way that unlock works is that Apple has a database of phones that should be unlocked. Type your IMEI into http://dev.mk/2012/08/dev-mk-iphone-imei-checker-with-simlock-status-what-happened/ and it should tell you.
Now it is pretty unclear how to make the unlock work as there isn't any visible way I've found to check it, but AT&T recommends that you backup and then restore from backup your phone. This didn't work.
Apple recommends that you:
- Connect to iTunes and backup
- then do a restore (that is it wipes everything and forces activation)
- then restore from backup.
This makes some sense to me as it forces the activation process again which does the IMEI check.