Some cell phones are designed to use a Subscriber Identification Module (SIM) card, or Memory Chip that stores subscriber data. The SIM card is issued by a carrier and provides cell service by activating any phone into which it is placed into. A locked phone, however, will only recognize a SIM card from a particular carrier. If the cell phone is unlocked, it will recognize a SIM card from any carrier. The "lock" is a software setting that keeps the cell phone "locked" to one carrier.
In areas like the USA where carriers offer free or discounted phones with cell plans, the phones are commonly locked so that they will not work with other carriers. Carriers claim this is necessary to cover the cost of the phones but I do not believe this is the case since you have to sign a contact in order to receive a free or discounted cell phone from carriers in the first place.
From the perspective of the customer, carriers locking phones and using proprietary settings defeats many of the benefits of handsets that use SIM cards. Ideally phones should be left unlocked, or at least unlocked after the initial contract expires.
One way to get an unlocked phone without proprietary settings is to buy it new from a third party vendor in its original, unlocked state. The upside is that the price is commonly close to 60% of retail. Some consumers may find it easy to do this because they ca upgrade whenever they like. The other advantage is that the third party unlocked phones work equally well with any carrier that uses SIM cards for their service.
Unlocked cell phones are in such high demand that third party companies will unlock your cell phone for a price. This does not mean the phone will always work normally, as proprietary you carriers settings may remain. There are also instructions on hacking to unlock many brands of phones, but a phone that is hacked or improperly unlocked can be rendered unusable.
Carriers that use SIM cards and are on GSM networks include:
Cingular Wireless, AT & T Wireless, and T-Mobile.