Are you upgrade eligible? If not, you will not be able to switch at all. If you are in a position to start a new 18 month contract, then there's a pricing guide grid thingy on the iPhone section of the O2 website.
The only O2 customers that were allowed to early upgrade for free were existing iphone ones.... everyone else is bound by the contact until termination... whether you pay to get out early is then your choice.
My brother had to pay £130 to get out of his current contract. Once he paid this, he just paid £59 for the iPhone 3G 16GB on a £45 a month contract.
If your eligible to upgrade, i.e. at the end of your contract, you can just upgrade like normal and pay for the iPhone etc depending on the monthly plan you chose.
I had 5 months left on a non iphone contract. I upgraded and they still havn't charged me for the phone at all and there is no sign of any contract cancel fee yet either.
I was in a position where I was on an 18 month contract even though I believed I was on an 12 month contract and I had phoned up severeal times to discuss my options.
hope they're gonna let me upgrade without paying the early termination fee. but still i'm gonna keep on waiting until the 16gig white model becomes available for upgrade!