North Carolina Gov. Pat McCrory makes remarks concerning House Bill 2 while speaking during a government affairs conference in Raleigh, N.C., Wednesday, May 4, 2016. A North Carolina law limiting protections to LGBT people violates federal civil rights laws and can't be enforced, the U.S. Justice Department has said. Photo: AP Photo/Gerry Broome

North Carolina Gov. Pat McCrory makes remarks concerning House Bill 2 while speaking during a government affairs conference in Raleigh, N.C., Wednesday, May 4, 2016. A North Carolina law limiting protections to LGBT people violates federal civil rights laws and can't be enforced, the U.S. Justice Department has said. Photo: AP Photo/Gerry Broome

DURHAM, N.C. (AP) — North Carolina Gov. Pat McCrory conceded the governor’s race Monday, clearing the way for Democrat Roy Cooper to be declared the winner nearly four weeks after Election Day.

The win by Cooper, the state’s outgoing attorney general, gives Democrats an important consolation prize after a disappointing election across the country. However, Republicans retain super majorities in both legislative chambers.

In a video message from his office posted to YouTube, McCrory said, “Despite continued questions that should be answered regarding the voting process, I personally believe that the majority of our citizens have spoken, and we now should do everything we can to support the 75th governor of North Carolina, Roy Cooper.”

McCrory, who became the first sitting North Carolina governor to lose a re-election bid, was weighed down by a series of divisive laws he signed, including House Bill 2.

That law limited LGBT rights and directed transgender people to use restrooms in schools and government buildings corresponding to the sex listed on their birth certificates. It led to companies, sports organizations and entertainers pulling their business from the state, costing hundreds of jobs and millions of dollars in spending.

With appeals drying up and postelection counts padding Cooper’s narrow lead, McCrory announced he was giving up.

McCrory, who won the office by a comfortable margin four years ago, was unable to generate the same voter support that lifted Republicans Donald Trump and Richard Burr to victory in the state.

Unofficial results at the State Board of Elections showed Cooper leading McCrory by slightly more than the 10,000 votes needed to avoid an automatic recount. A total of about 4.7 million votes were cast. The state board still must officially certify the results.

Cooper was expected to speak later Monday.

Cooper has stated he wants HB2 repealed because he said it promotes discrimination and has harmed North Carolina’s brand as good place to do business.

McCrory defended signing the law and unsuccessfully tried to focus his campaign on the state’s recovering economy and finances during his four years in office. Flooding after Hurricane Matthew in October also gave McCrory the opportunity to project the image of a leader as he directed recovery efforts as cameras watched.

Cooper, a former state legislator first elected attorney general in 2000 won’t enter office from a position of strength. Republicans hold veto-proof majorities in both chambers of the legislature, making it difficult for him to push his agenda — or stop theirs.

© 2016, Associated Press, All Rights Reserved.

This material may not be published, broadcast, rewritten, or redistributed.