President Donald Trump reacts to a question during an interview in the Oval Office of the White House in Washington, August 20, 2018.

President Donald Trump said Wednesday that he only knew "later on" about hush-money payments made by his ex-lawyer Michael Cohen to multiple women ahead of the 2016 presidential election.

Trump also said the larger question is not whether he knew about the payments, but whether the money came from the Trump campaign itself.

"You have to understand, Ainsley, what he did — and they weren't taken out of campaign finance," Trump said in an interview with Fox News host Ainsley Earhardt.

Trump added: "In fact, my first question when I heard about it was, 'Did they come out of the campaign?' because that could be a little dicey. And they didn't come out of the campaign, and that's big."

Trump Fox tweet

In July, it was revealed that Cohen made a secret recording of him talking to Trump about paying off Playboy model Karen McDougal to keep her quiet about her alleged affair with Trump.

White House press secretary Sarah Huckabee Sanders later referred questions about when the president knew about the payments to McDougal and porn star Stormy Daniels to his outside attorneys.

Cohen on Tuesday pleaded guilty to charges filed by federal prosecutors in Manhattan, including tax fraud and campaign finance violations.

Cohen's lawyer, former Clinton White House aide Lanny Davis, said Tuesday that Cohen testified under oath that "Donald Trump directed him to commit a crime by making payments to two women for the principal purpose of influencing an election."

In the Wednesday interview, Trump took another opportunity to bash his predecessor, President Barack Obama, and his own attorney general, Jeff Sessions.

"You look at President Obama, he had a massive campaign violation," Trump said. "But he had a different attorney general, and they viewed it a lot differently."

Trump referenced that fine in a tweet earlier Wednesday.

Trump tweet Obama fine

Politico reported in 2013 that Obama's 2008 presidential campaign was fined $375,000 by the Federal Election Committee.