Democratic gubernatorial candidate Lt. Gov. Ralph Northam, left, and GOP gubernatorial candidate Ed Gillespie, during their first debate in Hot Springs, Va., on July 22. (Bob Brown/Richmond Times-Dispatch via AP)

The Republican and the Democrat running for Virginia governor each picked up seven-figure campaign contributions from national groups after their first debate.

Not 30 minutes after Ed Gillespie and Ralph Northam stepped off the debate stage Saturday, the Republican Governors Association announced it would plow $2 million into Gillespie’s campaign — on top of a previous ­$1 million donation.

And on Tuesday, the Democratic National Committee said it would give $1.5 million to Northam, the state’s lieutenant governor. The DNC also dispatched three top staffers to Virginia to work with his campaign. That help is on top of the $1 million the Democratic Governors Association gave the day after the primary.

Also Tuesday, Gillespie announced that he will launch statewide TV ads — the first of the general election.

The race for Virginia governor is the country’s marquee statewide contest this year, and it is expected to draw national money and attention until the November election. Both parties are viewing the contest as a referendum on President Trump that could also presage the outcome of the 2018 midterms.

A recent Monmouth University poll of likely voters found Northam and Gillespie tied, at 44 percent each. They are vying to succeed Gov. Terry McAuliffe, a popular Democrat who is prohibited by law from seeking a consecutive term.

The RGA called its $2 million donation to Gillespie a “response to the impressive leadership he demonstrated in the debate.”

“Virginia is a top pickup opportunity for Republicans and the RGA is proud to partner with Gillespie’s campaign as an early investor,” Wisconsin Gov. Scott Walker, chairman of the RGA, said in a written statement. “With this additional major investment, the RGA is proving once again that we are all-in to ensure Ed has the resources to win in November.”

The DNC put its donation to Northam, first reported by NBC News, in similar terms.

“The DNC is all-in in Virginia,” Chairman Tom Perez said in written statement. “We are training organizers, doubling our boots on the ground, and making significant investments in our digital and data operations that will help lift Democrats to victory up and down the state ballot.”

Perez dispatched his chief of staff, Sam Cornale, to work with Northam’s campaign, along with the DNC’s political and organizing director, Amanda Brown ­Lierman, and political adviser Ramsey Reid. Some Republicans suggested the DNC was sending staff because of perceived weakness in Northam’s organization. Northam spokeswoman Ofirah Yheskel pushed back against that notion.

“The momentum in the race has been and remains with Dr. Ralph Northam, who has outraised, outdebated, and outclassed Ed Gillespie in every head to head contest,” Yheskel said in an email. “The RGA has propped Ed Gillespie’s campaign up with ­$3 million since his near upset to a neo-confederate in the primary. No matter how hard Republicans try to spin, Democrats quickly united in the Virginia governors race and the DNC’s investment of staff and resources are [a] reflection of that coordination.”

Northam raised $9.4 million for the governor’s race by June 30 compared with $6.7 million for Gillespie. Northam spent all but $1.75 million fighting off former congressman Tom Perriello in the Democratic primary, which Northam won by 12 points.

Gillespie, widely expected to coast to victory in his three-way primary, spent relatively little but barely eked out a victory over Trump acolyte Corey Stewart, who focused his campaign on the preservation of Confederate monuments.

Starting Wednesday, Gillespie will air three ads statewide, according to his campaign, which declined to comment on the duration or dollar value of the ad buys. One of the ads touts his plan to improve the economy by cutting taxes, spending and red tape.

The others highlight Gillespie’s humble roots. In one, “American Dream,” he recalls his Irish-immigrant grandfather, who worked as a janitor. The other, “Odd Jobs,” is a more lighthearted take that shows him juggling plates of food, pouring beer and deftly backing into a cluttered garage.

“I learned a lot in college, like how to carry four plates in two hands, how to properly serve a beer, and I learned how to park large cars in small spaces,” he says. “I know about working hard to get ahead. But today, too many Virginians are working hard and feeling stuck. I know we can do better, and as governor, I’ll make sure we do.”