Gov. Larry Hogan and former Lt. Gov. Anthony Brown walk the center aisle as they arrive together for the swearing-in ceremony for 141 members of the House of Delegates on Jan. 14 in Annapolis. (Jonathan Newton/The Washington Post)

If Maryland’s race for governor had been decided by those who stayed home on Election Day, Lt. Gov. Anthony G. Brown (D) would have been the runaway winner, a Washington Post-University of Maryland poll has found.

The poll, along with newly released state voting data, offers a fuller picture of how Republican Larry Hogan became the governor in such a heavily Democratic state. While GOP turnout was down slightly from four years earlier, Democratic participation fell considerably more. Hogan successfully wooed independents and disaffected white Democrats, while Brown struggled to get voters from his party to the polls and performed less well than hoped among African Americans, a core constituency.

The findings suggest lessons for both parties as they look to the future in a state where registered Democrats outnumber Republicans by more than 2 to 1.

To reclaim the governorship in 2018, Democrats will need a candidate with a crisper message who is more capable of motivating the party’s base, analysts and strategists say.

For Hogan to win reelection, he must not alienate the Democrats who voted for him — a large chunk of whom share his concern about high taxes and spending but disagree with him on other issues.

Explaining Larry Hogan's stunning victory in Maryland

“Hogan has to govern from the center,” said Donald F. Norris, director of the School of Public Policy at the University of Maryland Baltimore County. “Maybe center-right is okay. But he can’t govern from the right. . . . Hogan can get all the Republican turnout he wants next time and still not win in Maryland. He needs [votes from] Democrats.”

In November, 59 percent of eligible Republicans voted in the governor’s race. That was down from 62 percent four years earlier, when incumbent Gov. Martin O’Malley (D) soundly defeated former governor Robert L Ehrlich Jr. (R).

Democratic turnout, meanwhile, dropped from 55 percent to 47 percent.

And those who did not vote in November, the poll found, preferred Brown over Hogan 46 percent to 35 percent.

Thirty-seven percent of white Democrats and Democratic-leaning independents voted for Hogan — a key part of his winning constituency. Only 11 percent of this group supported Ehrlich for governor in a 2010 pre-election poll.

Hogan was able to peel off Democrats who had voted for Republicans before, as well as some who had not.

Janet Ensor, 48, a retired Baltimore police officer and registered Democrat who lives in Harford County, said she was convinced “we needed a change.” She said she was tired of “all the taxes and the constant running out of money” in Annapolis.

Martin Gold, 68, who lives in Bethesda and works as a federal government lawyer, voted for Hogan, too, after “many second thoughts.” He said he was convinced that Hogan would spend tax revenue more wisely than Brown.

Nearly 3 in 4 Democratic-leaning Hogan voters disapproved of O’Malley’s performance as governor, and one-third called taxes­ their top issue — far more than Democrats who stuck with Brown.

But majorities of Hogan Democrats disagree with the Republican on issues such as the minimum wage and fracking, the poll found. And two-thirds opposed a key proposal by the governor to balance next year’s budget: slowing the growth of education spending.

Democratic officials are hopeful that as more issues like that emerge, party members who took a risk on Hogan will regret their vote. “Now that he’s attempting to govern, people are realizing that elections have consequences,” said Bob Fenity, executive director of the Maryland Democratic Party.

Joe Cluster, executive director of the Maryland Republican Party, acknowledged that one of Hogan’s challenges is “holding on to the collection of people who voted for him.” But Cluster argued that if Hogan makes good on his promises­ — including tax relief — “that coalition stays together more easily than people might think.”

In the meantime, the GOP is looking for groups of voters who could be more receptive to Hogan’s message, including African Americans who may like his support for charter schools, and wealthy Montgomery County residents who may want to lighten their tax bill.

Don Murphy, a former legislator and Republican consultant, said voters will give Hogan some leeway on issues on which they disagree as long as the governor is straight with them and stands by his convictions.

Democrats say they are determined to find a candidate in 2018 who can better connect with the party’s base. While the party needs to win back white voters, Brown — who would have been Maryland’s first African American governor — also fell short of expectations with black voters.

In the Post-Maryland poll, 79 percent of blacks who voted said they supported Brown, compared with 88 percent who supported O’Malley in a Post poll shortly before the 2010 election. President Obama, in contrast, received 97 percent support from black voters in 2012, according to an exit poll conducted by Edison Media Research.

Cliff Matthews, 38, was among the African Americans who stayed home on Election Day. “I was leaning toward Anthony, but I just didn’t feel either one of the candidates was going to hold to their word,” said Matthews, a Democrat who lives in Montgomery County and provides security at a sports bar.

Several names have already surfaced as potential Democratic candidates in 2018, including Prince George’s County Executive Rushern L. Baker III; former Howard county executive Ken Ulman, who was Brown’s running mate; Comptroller Peter Franchot; Baltimore County Executive Kevin Kamenetz; U.S. Rep. John Delaney; and U.S. Labor Secretary Thomas Perez, a former O’Malley Cabinet member.

The fact that there is no single “obvious candidate” could be a good thing for the party, said veteran Democratic strategist Mike Morrill. “That means there’s going to have to be a debate about message, which will make the party stronger,” Morrill said.

The Post-University of Maryland poll was conducted Feb. 5-8 among a random sample of 1,003 adult residents of Maryland interviewed by telephone, including 160 cellphone-only respondents. The margin of error among 911 registered voters in the poll is plus or minus four percentage points; the error margin is 4.5 points among the sample 704 voters in the 2014 gubernatorial election.

Peyton M. Craighill contributed to this report.