President Obama’s views on gay marriage continue to “evolve,” with the president now saying he views same-sex marriage as a constitutional right.

In an interview with the New Yorker the president was quoted as saying, “Ultimately, I think the Equal Protection Clause does guarantee same-sex marriage in all fifty states.”

The statement, coming as the courts clear the way for gay unions in more states, would appear to complete a long shift for the president, who for years has grappled with the issue.

The first time he publicly expressed his views on the subject was back in 1996 when the then-Illinois state Senate candidate said he favored legalizing same-sex marriage and “would fight efforts to prohibit such marriages.”

However, in 2004 while running for U.S. Senate, Obama said marriage is between a man and a woman – though he continued to back civil unions.

In 2008, during coverage surrounding the controversial Defense of Marriage Act, Obama wrote an open letter saying he felt DOMA should be repealed, but as recently as 2010 was still “unwilling to sign on to same-sex marriage” because of “(his) understandings of the traditional definitions of marriage.” He acknowledged “attitudes evolve, including mine.”

In May 2012, during the presidential campaign, Obama declared his support for same-sex marriage.