Virginia Gov.-elect Ralph Northam, right, with Gov. Terry McAuliffe at an election night rally in Fairfax. (Win Mcnamee/Getty Images)

The success of Democrats in last week's Virginia elections was a political windfall for Gov. Terry McAuliffe, raising his profile as a potential presidential candidate in 2020.

His party's unexpectedly strong victory — taking governor, lieutenant governor and attorney general by wide margins, and coming within a hair of gaining control of the House of Delegates — added to McAuliffe's bragging rights as a Democrat who knows how to win in the era of Donald Trump.

It was McAuliffe who put Gov.-elect Ralph Northam on a course for the top job, recruiting him four years ago to run for, and win, lieutenant governor. And Northam triumphed last week on promises to continue McAuliffe's policies of protecting and expanding civil rights for women and minorities as a way to woo business and build Virginia's economy.

McAuliffe also delivered Virginia last year for his longtime friend Hillary Clinton — the only Southern state to resist the Trump tide.

Seen just four years ago as a hard-partying wheeler-dealer who made his name raising money for the Clintons, McAuliffe — who is prohibited by the state constitution from seeking a consecutive term as governor — has new national gravitas.

"It makes him a bit of a hero to a new generation of Democrats — millennials and other people who don't necessarily remember his time with [the Clintons]," said Jennifer Duffy of the Cook Political Report. "I bet that he suddenly finds himself a sought-after speaker at state party dinners, and candidates could ask him to campaign with them."

As University of Mary Washington political scientist Stephen Farnsworth put it: "It would not surprise me if Virginia's current governor started spending a lot of time in Iowa and New Hampshire come January."

McAuliffe's ambition is widely assumed around Richmond, though the governor himself has been coy about it. Asked on election night about his prospects for running in 2020, he demurred.

"This is a great night for Virginia," he said. "Tonight, I'm celebrating Ralph."

But he also knew the country was watching, via CNN and other network cameras, and made his case as a leader who has figured out the formula at a time when the national party is fractured and uncertain about the path back to power. "This is the revitalization of the Democratic Party in America. This isn't just about Virginia tonight," he said.

Virginia general election guide

"What this should tell Democrats," McAuliffe said the next day, "if you're going to win, you've got to run on values you believe in. Make it about economy and jobs" — and connect that to social issues, as he has.

McAuliffe departed later Wednesday for Europe, mentioning that "I'm going to be speaking in Parliament, going to Oxford" and attending U.N. climate negotiations in Germany.

At 60, McAuliffe has an extensive political network built over decades in national politics, relationships nurtured by his varied stints as the top fundraiser for Bill Clinton's presidential campaign, head of the Democratic National Committee and, last year, chair of the National Governors Association.

Once he leaves the governor's mansion in January, McAuliffe will be doing exactly what a prospective presidential candidate should do: traveling around the country, working to get members of his party elected in every state.

He has signed on to help former U.S. attorney general Eric H. Holder Jr. in his effort to influence redistricting around the country, aiming to rebuild the Democratic Party's infrastructure at all levels. McAuliffe referred to that last week when asked about his presidential plans in a radio interview on WAMU-FM (88.5).

"I'm also going to take a lead on winning the 36 governors' races, so I will be very visible, very much traveling around the country next year," he said.

But there's a long way to go and a lot of baggage to shed to get McAuliffe to the 2020 campaign. There is already a crowded field of hopefuls, Duffy said, and McAuliffe's Clinton connections will be a drag for those Democrats who are eager for new leaders.

"In 2016, they nominated a well-known, establishment candidate and that didn't go so well," she said. "My guess is they sort of make a 180 in 2020, and the establishment Democrats may struggle. And I think that given McAuliffe's long past in Democratic politics he'd probably fall into that category."

What's more, Virginia's big week could lose luster if Democrats fail to build on that momentum in races next year. Anti-Trump sentiment was a huge factor in the wins — even McAuliffe was caught off guard by the scope of Democrats' success in House of Delegates races.

With some contests still too close to call, Democrats are set to pick up at least 15 seats in the 100-seat House, and could get a 50-50 split after being down 66-34 the past two years. As recently as the Sunday before the election, McAuliffe had been predicting gains of about a half-dozen seats.

Not all Democrats think McAuliffe deserves credit for those wins. Some of the House candidates were aided more by progressive groups than by the state party apparatus.

"It was obviously a huge win for Democrats on Tuesday but not necessarily a win for any particular brand of Democrat," said Jeff Weaver, who managed the insurgent presidential campaign of Sen. Bernie Sanders (I-Vt.) last year.

The Virginia elections look a lot better in hindsight than they did a few weeks ago, he said. At DNC meetings in Las Vegas last month, "there was almost a panic about what was going on in Virginia," Weaver said — panic that the state was going to blow its big chance.

He credited some progressive groups — such as Our Revolution, a group he formerly led — with mobilizing money and volunteers to get the legislative candidates elected, drawing voter turnout that then benefited the top of the ticket.

Weaver said McAuliffe deserves respect for his governing of Virginia, where the unemployment rate is 3.7 percent. But if he runs for president as an establishment candidate, he will "have to explain how 2020 is going to be different from 2016," Weaver said.

McAuliffe is a natural campaigner: a loud, animated politician who fills up any room and is always half-jokingly introduced around Virginia as "his excellency." He has won praise even from Republicans for his tireless salesmanship, which he uses to recruit companies to the state. McAuliffe is widely known for crowing about every new business, from Humm Kombucha opening a brewery in Roanoke to Facebook announcing a billion-dollar data center in Henrico County.

It could be that his image as a dealmaking, jobs-creating, civil rights-protecting defier of Trump will be enough to get him a serious look in other states.

"What people are looking for now, they're looking for leaders who say what they believe, then follow up with action. And I think that's where Governor McAuliffe has a very strong record, he doesn't hem and haw," said Cecile Richards, the national head of Planned Parenthood.

The group was one of the biggest donors to Virginia Democrats this year, giving more than $2.3 million to multiple candidates, according to the Virginia Public Access Project.

Richards praised McAuliffe for his track record of protecting funding for Planned Parenthood and standing up to Republican efforts to restrict women's access to health care. "If health care continues to be as prevalent an issue as it has been over the last year . . . I think that helps him certainly with women all across the country and gives him something to distinguish himself compared with other leaders," she said.

Some Republicans have taken note. John Fredericks, a conservative radio host who helped run Trump's presidential campaign in Virginia last year, has become a grudging McAuliffe fan. He has praised the governor for his economic development efforts and conceded that McAuliffe's push to unlock federal dollars by expanding Medicaid, which the Republican-controlled General Assembly has so far resisted, was probably the right call.

"He would be the one to bring the working-class jobs debate to Trump's base and make the argument that he could peel some of it away in the battleground working-class swing states," Fredericks said. "I fear Terry McAuliffe more than any other candidate in the Democratic field in 2020."

Few others will go that far, but after last Tuesday's strong showing, McAuliffe has at least earned mentions in the chatter about presidential contenders.

"It sure doesn't hurt, let's put it that way," said Republican pollster Whit Ayers. "But any Democrat who has hopes of national prospects has got to figure out how to bridge the governing-Democrat-versus-Bernie-socialist divide, and I don't think anyone has quite figured that out."

Laura Vozzella and Jenna Portnoy contributed to this report.