T-Mobile branded phones operating on the T-Mobile network may only use T-Mobile SIM cards. To use a T-Mobile branded phone on another wireless carrier's network with a non-T-Mobile SIM card, you must first request a "SIM Unlock" code from T-Mobile. Conversely, if you have a phone from another North American wireless carrier, you may need to request a "SIM Unlock" code from that carrier before being able to use a T-Mobile SIM card on the T-Mobile network.
The unlock request should contain the following information:
- Account holders name (required)
- T-Mobile phone number (required)
- IMEI Number
- Account Password or last four digits of the account holder's SS number
- Contact number or email address
- Make and model of the phone
http://www.t-mobile.com/Contact.aspx