I already get my google mail on my iPod Touch (same as the iPhone minus the phone), but I wanted to sync my calendar and contacts too. There are few apps out there that provide this information, but that means having an additional application instead of just using Apple's onboard apps.
Enter NuevaSync (www.nuevasync.com). The program acts as a Microsoft Exchange Server for your calendar and contacts. You sign up at nuevasync.com and give the site access to select parts of your Google account. Then, on the iPhone, you add a new Exchange account, enter your nuevasync sign on information and put in the website as a server - voila.
Here are detailed instructions on how to perform this function. Ironically, they are not on the nuevasync site. NuevaSync is a great product with lowsy instructions; still, that's better than great instructions with a lowsy product.