Actress Julianne Moore will play Republican vice-presidential candidate Sarah Palin in an HBO production, Game Change, which traces the story of the 2008 US election.

Palin, then a little-known governor of Alaska, was plucked from obscurity to join John McCain’s ticket and immediately emerged as a divisive figure, becoming a darling of the party’s hardcore but alienating many independent and Democrat voters.

The HBO production will be an adaptation of a book written by written by Mark Halperin and John Heilemann, which revealed dozens of private conversations between members of McCain’s staff.

In one such exchange, McCain adviser Steve Schmidt was quoted telling Palin’s foreign policy advisers that, after testing the candidate before a debate, “You guys have a lot of work to do. She doesn’t know anything.”

Palin remains a powerful figure in the US conservative movement, with speculation growing that she may soon announce her candidiacy for the 2012 presidential election.