As the Democratic nominee for president in 2008, then-Sen. Barack Obama appeared at a forum hosted by Pastor Rick Warren. Obama was asked how he defined marriage.

"I believe that marriage is the union between a man and a woman," Obama said. "Now, for me as a Christian — for me — for me as a Christian, it is also a sacred union. God's in the mix."

This wasn't a new position for Obama — his public opposition to gay marriage was well-established. In a 2004 debate while running for the Senate in Illinois, Obama said, "I'm a Christian, and so although I try not to have my religious beliefs dominate or determine my political views on this issue, I do believe that tradition and my religious beliefs say that marriage is something sanctified between a man and a woman."

No one ever really believed that Obama opposed gay marriage — his signature on a 1996 questionnaire stating his support served as evidence of his private beliefs, and his 2010 claim that he was "evolving" on the issue was an indication that he privately supported marriage equality. But Obama didn't publicly support gay marriage until May 2012, and only after his hand was forced by his own vice president.

Now, thanks to a new book by longtime Obama confidant David Axelrod, we know definitively that Obama lied to the American public about his beliefs. He and his administration repeatedly misled the public about his views on gay marriage, and in doing so failed to live up to the standards of forthrightness and honesty that he himself had set for his presidency.

Axelrod's revelation: Axelrod was one of Obama's earliest and closest advisers, and had a front-row seat to his rise to power and his time in the White House. As Timefirst reported, Axelrod details in his book Believer: My Forty Years In Politics how Obama really felt about gay marriage during his first term:

[I]f Obama's views were "evolving" publicly [in 2010 and 2011], they were fully evolved behind closed doors. The president was champing at the bit to announce his support for the right of gay and lesbian couples to wed — and having watched him struggle with this issue for years, I was ready, too. Jim Messina, the campaign manager, was nervous about the impact of such a step. "We've looked at this and it could cost you a couple of battleground states; North Carolina, for one," he said. By year's end, however, Obama was no longer interested in analysis. "I just want you guys to know that if a smart reporter asks me how I would vote on this if I were still in the state legislature, I'm going to tell the truth. I would vote yes."

Axelrod writes that Obama "routinely stumbled over the question when it came up in debates or interviews." The president is quoted as saying "I'm just not very good at bullshitting" after one such incident.

US President Barack Obama speaks alongside the White House senior advisor David Axelrod during a meeting with Russian opposition leaders in Moscow on July 7, 2009. SAUL LOEB/Getty Images

A failure to live up to his own standards: All politicians bullshit, of course, and some are better at it then others. But much of Obama's appeal as a candidate in 2008 came from the perception — encouraged by the candidate and his campaign — that he would usher in a new kind of politics, one in which hard questions were met head-on and with a spirit of bipartisan unity. Obama would lead the charge, communicating clearly with the American people about the issues the country faced and his plans to fix them. Honesty was at the core of this transaction between Obama and those he asked to vote for him.

It is true that the promise of Obama was almost certainly too lofty to be realized in the real world of governing. But his failure to live up to that promise in areas besides gay marriage is often chalked up to the need to cut deals with an intransigent Republican Party in Congress. The compromises that were necessary to pass the Affordable Care Act and tougher Wall Street regulation are often criticized by liberals as unnecessary concessions. But even if in their view he gave away too much, at least they knew where he stood when he got to the bargaining table.

And a misguided calculation: Gay marriage is different. On no other issue was Obama so needlessly and deliberately misleading in his public pronouncements. Axelrod writes that the main obstacle to Obama embracing marriage equality earlier was a political calculation that doing so would cost him votes in the next election, particularly among black churchgoing voters with conservative views. This concern was by 2010 at best overblown, at worst cynical, and ultimately unfounded. By the time Obama embraced gay marriage in 2012, the American public's opinion on the issue was already rising in support.

There is no evidence that his support for marriage equality cost him votes in 2012. And while his cautiousness may have been more credible in 2008 when the country had yet to come around on gay marriage, his delay in making his true feelings known for years while in office plays into a popular criticism of his presidency overall — namely, that his cautious nature prevents him from taking controversial stands on important national issues.

Obama's approach here wasn't terribly detrimental to the lives of gay and lesbian couples, thankfully. As Jonathan Chait notes, Obama's opposition to gay marriage before 2011 had little impact on a policy level: "Lying about his stance on a mostly abstract policy issue is not the same as lying about whether he'd sign a health-care bill."

But it is still lying. And if we are to hold Obama to the standard he set for himself as president, we can't overlook the fact that he was dishonest about his views on an issue that impacts the lives of millions of Americans. Everyone knew better at the time. Obama should have, too.