A noisy fight this week between President Trump and former vice president Joe Biden over a major union endorsement foreshadows a fierce political battle to come for the support of labor voters in the 2020 campaign.

As Trump seeks to drive a wedge between union members and their leaders in his bid for reelection, he lashed out at Biden for nabbing an endorsement from the International Association of Fire Fighters at his campaign kickoff rally in Pittsburgh.

“I’ve done more for Firefighters than this dues sucking union will ever do, and I get paid ZERO!” Trump tweeted early Wednesday.

The president followed that missive with more than 60 retweets of obscure Twitter accounts, mostly attacking Biden and praising Trump as more desirable to union voters.

The predawn flurry highlighted how the president and his allies see Biden as a top threat, in part because of his appeal to blue-collar voters in key states that propelled Trump to victory in 2016.

Promising to rip up old trade deals, restore U.S. manufacturing and stand up for the “forgotten man,” Trump relied on working-class white voters to win states such as Michigan, Wisconsin and Pennsylvania en route to his electoral college victory. But his party suffered major losses in 2018 in each of those states, which together have more than 1.5 million union members, according to the Labor Department.

“In the last presidential election, Trump presented himself as a savior for the white working class . . . and he sees groups like firefighters and police unions as his base,” said Ileen DeVault, academic director of The Worker Institute at Cornell University. “If Trump loses that slight edge he has in those states because of union votes, that will be bad for him. He doesn’t have much margin for error.”

Many Democrats are convinced that the path to ousting Trump from office includes winning back more blue-collar workers.

“I make no apologies — I am a union man,” Biden said Monday at a Pittsburgh rally kicking off his presidential bid with a direct appeal to labor. “The country wasn’t built by Wall Street bankers, CEOs and hedge fund managers. It was built by you. It was built by the great American middle class.”

During the rally, which was hosted by the firefighters union, Biden attacked Trump’s corporate tax cuts and other policies that have benefited the wealthy. Biden, who has referred to himself as “Middle-Class Joe,” is quickly emerging as a top target for Trump’s reelection bid, which previously had been reluctant to single out any specific candidate in the crowded Democratic field.

In a lengthy statement Wednesday, Trump campaign spokeswoman Kayleigh McEnany attacked Biden for his support for multinational trade deals such as the North American Free Trade Agreement and the Trans-Pacific Partnership while comparing Trump’s record on wages and manufacturing to former president Barack Obama.

“Union workers across the nation were betrayed during the Obama-Biden years,” she said. “Joe Biden was a cheerleader for the job-killing Trans-Pacific Partnership, advocating for trade deals that hurt workers, failing to revive manufacturing, and leaving union members in the dust. Hard-working men and women in labor unions remember this.”

With his string of retweets Wednesday morning, Trump highlighted dozens Twitter accounts that claimed to represent firefighters who disagreed with IAFF’s decision to endorse Biden. It was not clear how many of the accounts were real, but at least one appeared to be a ruse: After the president retweeted the account, it changed its name to an anti-Trump obscenity.

The president’s broader message, echoing his previous comments, was that rank-and-file union members will support him even as labor leaders back Democrats.

“I’ll never get the support of Dues Crazy union leadership, those people who rip-off their membership with ridiculously high dues, medical and other expenses while being paid a fortune,” Trump tweeted Monday. “But the members love Trump.”

IAFF President Harold A. Schaitberger said that while some of his members support Trump, Biden’s decades-long record on labor issues was rock solid. By contrast, he said, Trump has supported efforts to roll back unions and strip collective bargaining rights, and threatened to pull federal funding from California last year during massive wildfires.

But Schaitberger said union officials do not want to get into a tit-for-tat with the president.

“Our decision certainly has gotten under the president’s skin,” he said. “The president’s tweet isn’t worth our response. I wouldn’t dignify it with a response.”

The IAFF stayed out of the 2016 election, declining to endorse Democrat Hillary Clinton in her bid against Trump.

Labor unions, which long have been the backbone of Democratic fundraising and organizing, have become a top target for the Trump’s campaign as it seeks to capi­tal­ize on a strong economy. Trump has held several official events this year, making a direct appeal to blue-collar union workers — from border agents to operating engineers.

Last month, Trump stood in front of hard-hat-wearing men and women at a union-run heavy equipment training facility in Crosby, Tex., and played up his relationship with labor.

“As I’ve said from Day 1, American labor will always have a friend in the White House,” he said. “You know that. I’ve proven that.”

Trump is pushing for a renegotiated NAFTA this year and also has revived his calls for massive infrastructure investment, promises from his 2016 campaign that appealed to some union members.

But critics say that Trump has failed to deliver on his promises to working men and women, instead siding with corporations to cut their taxes and weaken employee protections.

“How about we stop doing bad things?” Sen. Elizabeth Warren (D-Mass.) asked Saturday during a forum on wages and workers organized by the Service Employees International Union. “How about not having a Department of Labor that is classifying more and more employees as independent contractors, because once they’re independent contractors, they can’t organize?”

Galen Munroe, a spokesman for the Teamsters union, said the organization is still in the process of deciding which candidate to endorse. The union, he said, will be a formidable force in organizing and “knocking on doors” for its chosen candidate.

“We are very good at putting boots on the ground and supporting the candidate that we endorse,” he said.

Trump is seeking to peel off rank-and-file workers from their union leadership’s support from Democrats, a strategy he pursued with some success in 2016. Exit polls indicate he trailed Clinton among union households by only eight points, the best margin for a Republican since 1984.

“I want to deal with the people in the union. Not the heads of the union,” Trump said during a March visit to an Ohio manufacturing facility. “Your union leaders aren’t on our side. But the people who work there are on our side.”

That messaging appeals to voters such as P.J. Norwood, a firefighter in East Haven, Conn., who said he has heard from several colleagues who are unhappy with the IAFF’s embrace of Biden.

Norwood said rank-and-file firefighters are willing to look beyond some of Trump’s anti-union policies to support a president more aligned with them on “the bigger picture.”

“While he potentially might not support collective bargaining, we have the lowest unemployment rates out there and he’s brought more manufacturing jobs back to the United States,” he said. “If you’re bringing back more jobs to the United States, you’re supporting unions.”