President Trump slammed his former personal lawyer Michael Cohen Saturday — his first public reaction to reports that the attorney recorded at least one of their conversations in the run-up to the 2016 election.

“Inconceivable that a lawyer would tape a client — totally unheard of & perhaps illegal,” he fumed in an 8:10 a.m. tweet.

Trump also denounced the FBI’s April raid on Cohen’s home and office, which resulted in the seizure of the recording.

“Inconceivable that the government would break into a lawyer’s office (early in the morning) — almost unheard of,” Trump wrote.

“The good news is that your favorite President did nothing wrong!”

Cohen is under investigation for paying women, including porn actress Stormy Daniels, to keep quiet about their alleged flings with Trump.

On the tape, Cohen reportedly tells Trump that ex-Playboy model Karen McDougal, who claims she had a 2006 affair with Trump, sold the rights to her story to the National Enquirer’s parent company, American Media Inc.

The tabloid never ran the story, and in their conversation, Cohen reportedly suggests the then-GOP nominee should buy the rights himself.

No such purchase was ever made, Rudy Giuliani, Trump’s personal lawyer, said Friday. The president has denied both Daniels’ and McDougal’s claims.

Saturday’s tweet marked a stark change in attitude for Trump, who had previously called his longtime fixer “a fine person” and a businessman “who I have always liked & respected.”

“Most people will flip if the Government lets them out of trouble, even if it means lying or making up stories,” Trump tweeted on April 21. “Sorry, I don’t see Michael doing that.”

But three weeks ago, Cohen told ABC News that he would put “family and country first,” stoking speculation that he may turn on Trump.

“I will not be a punching bag as part of anyone’s defense strategy,” Cohen said. “I am not a villain of this story, and I will not allow others to try to depict me that way.”

Meanwhile, the Rev. Al Sharpton spoke about his eyebrow-raising new role as Cohen’s adviser.

Speaking at his weekly Saturday rally, the civil-rights activist said he had a one-on-one breakfast confab with Cohen, at the attorney’s request, at a Park Avenue hotel Friday.

“He said, ‘I do not agree with what Trump has started doing in terms of the media,’ ” Sharpton recalls in video of the rally posted to his Web site. “ ‘I know that I’ve always defended him, but there are many things he’s doing that I don’t agree with.’ ”

“And he said over and over again, ‘I’m going to do what is right for the country and my family.’ ”