"Half of My Heart" features more of a pop rock sound than Mayer's previous music. His previous albums explored blues and acoustic rock, especially in his 2006 album Continuum. It also has a carefree, sing-along sound to it.
The lyrics of the song are sung by both Mayer and Swift; Swift sings with Mayer in the chorus and in the song's bridge. The lyrics are about the duo, with half of their hearts saying they should continue to love each other, although the other half says they are not each other's true love, and cannot keep loving each other.
Mayer "tweeted" about wanting to record the song with Swift in March 2009: "Waking up to this song idea that won't leave my head. 3 days straight now. That means it's good enough to finish," he wrote. "It's called 'Half of My Heart' and I want to sing it with Taylor Swift. She would make a killer Stevie Nicks in contrast to my Tom Petty of a song."
In an interview shown on television called John Mayer: On the Record with Fuse (which only aired on the Fuse channel), Mayer's interviewer asked why the singer chose Swift to duet with, since she was only nineteen years old, and Mayer was 32. He responded by saying that he was not putting her on the album just to sell more copies for die-hard fans of Taylor Swift that might just get the album for that song.