If youve purchased your iPhone with a contract through AT&T or Sprint, and if youve financed your equipment and havent paid it off through T-Mobile U.S., youll need to call your carrier (usually just by dialing 611) and ask for an unlock code. Some customer service representatives will want to know why, and you can tell them that you will be traveling internationally. It may take a few daysup to a weekto get the code, so plan accordingly if you can.