Spurned by leaders of the party he just joined, Nassau County executive candidate George Maragos is turning to Twitter — much as President Donald Trump has — to lob bluntly worded insults and attacks at his opponents.

Maragos, the longtime Republican county comptroller who became a Democrat last fall, until this week largely limited his personal Twitter postings to formal campaign statements and photographs of himself at community events.

Then Nassau Democratic chairman Jay Jacobs, who had welcomed Maragos into the party in September, announced last Monday that he was endorsing County Legis. Laura Curran of Baldwin for county executive.

After a news conference at which Curran questioned Maragos’ independence as comptroller, calling him a “yes-man for corruption,” Maragos logged on and fired back.

“Dem Party Boss Press Conference turned into a Maragos bashing fest of trumped up lies to scare residents. The people will not be fooled,” Maragos wrote.

A dozen more tweets directed at Jacobs, Curran and the party’s choice for county comptroller, Jack Schnirman, followed into that evening and throughout the week.

Maragos said Curran’s the one who lacked independence (“#PuppetCurran”) and alluded to his previous spats with Republicans and his private-sector success, noting that he was “disliked by Insiders, does not need job.”

advertisement | advertise on newsday

He singled out Schnirman, the Long Beach city manager, for saying he would “open the books,” tweeting: “Someone should tell #CluelessJack Schnirman that the county books are already online.”

Finally, he targeted Curran’s resume. The former Baldwin school board trustee graduated from Sarah Lawrence College with a liberal arts degree, worked as a reporter for the New York Daily News and New York Post, and also has taught yoga.

“Here is a good laugh. The qualifications of the Dem Boss hand picked nominee for County Executive; BA of Arts, Reporter, Yoga Instructor,” Maragos wrote, punctuating the tweet with an emoji depicting tear-inducing laughter.

That tweet was deleted on Tuesday, after a reporter contacted Maragos. The rest remained.

“George’s opportunistic record speaks for itself,” Curran said in a statement that referred to his unsuccessful campaigns for U.S. Senate as a Republican in 2010 and 2012.

In the latter campaign, Maragos, 67, likened gay marriage to people “marry[ing] with their pets.” He later apologized, saying he had “evolved on some of those social principles.”

“We need a fresh start in Nassau County, but George Maragos has been a yes-man for the culture of corruption while spewing hatred towards our gay and lesbian brothers and sisters,” Curran, 49, said.

Maragos didn’t return a call for comment.

Hank Sheinkopf, a Democratic consultant who heads the Maragos campaign, said Maragos wasn’t consciously channeling Trump, but was simply responding to attacks on his record.

“If you consider how they treated him as a sitting comptroller of the county — in a demeaning fashion — his response was appropriate,” Sheinkopf said.

advertisement | advertise on newsday

Michael Dawidziak, a Bohemia political consultant who works primarily with Republicans, said it wasn’t surprising that local candidates would try tactics they’ve seen work nationally.

“The rule in politics, much like television, is, ‘If it works, copy it,’ ” Dawidziak said. “But whether it’s a smart thing to do or not? Trump was a phenomenon and still is. It’s very hard to think that he isn’t unique.”

Trump lost Nassau County last year to Democrat Hillary Clinton.

Jacobs said Maragos’ flurry of Twitter posts “validates the decision I made. He is definitely acting like a Trump Republican.”

Sheinkopf said “the Trump people are the Jacobs camp, because they don’t like democracy,” citing the party’s decision to back a candidate in what may be a three-person primary, rather than wait for a winner to emerge.

advertisement | advertise on newsday

Assemb. Charles Lavine (D-Glen Cove) has also announced a county executive bid.

Republicans have yet to name a nominee. County Executive Edward Mangano — a Republican who has pleaded not guilty to federal corruption charges — hasn’t said whether he would seek a third term.