President Barack Obama has said that he believes that the marriages of gay and lesbian couples should be recognized by the federal government regardless of whether there is state recognition.

Speaking to reporters in Dakar, Senegal, Obama applauded a Supreme Court ruling striking down the Defense of Marriage Act (DOMA). DOMA was signed into law by President Bill Clinton and prohibited federal agencies from recognizing the legal marriages of gay couples.

Roughly one-third of Americans live in states which allow gay couples to legally marry. The president said that such marriages may cross state lines.

“I think it was a victory for American democracy,” Obama said. “I believe at the root of who we are as a people, as Americans, is the basic precept that we are all equal under the law. We believe in basic fairness.”

“What's true though is that you still have a whole bunch of states that do not recognize it. The Supreme Court continued to leave it up to the states to make these decisions. And we are going to have to go back and do a legal analysis of what that means. It's my personal belief, I'm speaking now as a president as opposed to as a lawyer, that if you've been married in Massachusetts and you move someplace else you're still married. Under federal law you should be able to obtain the benefits of any lawfully married couple.”