FILE - Virginia State Capitol (House of Representatives)

The House of Representatives chamber in the Virginia State Capitol in Richmond, Virginia.

Democrats have taken control of the Virginia House of Delegates and the Virginia Senate, according to unofficial projections.

In the Senate, Democrats won 21 seats in the 40-seat chamber, according to the Washington Post, while Republicans retained at least 17 seats. The remaining two lean Republican but were too close to call late Tuesday.

In the House, the Post called 53 seats for Democrats in the 100-seat chamber and 41 seats for Republicans. Two other seats are leaning Democrat while three are leaning Republican. District 30 has a majority of votes going toward write-in candidates, which had yet to be counted.

In District 30, Del. Nick Freitas, R-Culpeper, was forced to run a write-in campaign after missing a deadline, but he was projected to win.

The new Democrat-controlled legislature will be working with Democratic Gov. Ralph Northam.

The Senate was expected to turn blue after they gained a number of seats in 2017, but the House had been more of a toss-up until a court ordered that district boundaries were racially gerrymandered and unconstitutional. When the legislature failed to agree on new district lines, the court ordered that a special master draw them, which put six Republicans in Democrat-leaning districts and no Democrats in Republican-leaning districts.

“The Democratic Legislative Campaign Committee made Virginia our top target in 2019 and that focus carried us to victory in the country’s most competitive election,” DLCC President Jessica Post said in a news release. “I want to congratulate all of our incredible candidates, the committed staffers and volunteers in Virginia, and our amazing national partners. Their hard work and dedication has pushed the commonwealth forward into a new chapter.”

Republican House Speaker Kirk Cox, R-Colonial Heights won a close race after being forced into a Democrat-majority district by the court-ordered redrawing of the maps. In a statement, he congratulated winners in both parties and said that he hopes that committees will be proportionally represented.

"When Republicans took the majority 20 years ago, we preserved proportional representation on committees and sought to treat our colleagues with the respect that should be afforded to all equal members in an institution as revered and esteemed as the House,” Cox said. “I hope and pray those traditions continue regardless of who wields power in the years to come.”

Northam said that Tuesday's victory for the Democratic Party shows that voters want the commonwealth to build on the agenda that his administration has begun.

“They want us to defend the rights of women, LGBTQ Virginians, immigrant communities, and communities of color,” Northam said. “They want us to increase access to a world-class education for every child, and make sure no one is forced to go bankrupt because they or a family member gets sick. They want us to invest in clean energy and take bold action to combat climate change. And they want us to finally pass commonsense gun safety legislation, so no one has to fear being hurt or killed while at school, at work, or at their place of worship.”

Northam remains at the center of a scandal in which he initially admitted appearing in black face in a college yearbook photo but later denied he was in the image. Senate and House Democrats in February called for his resignation.

Staff Reporter

Tyler Arnold reports on Virginia and Ohio for The Center Square. He previously worked for the Cause of Action Institute and has been published in Business Insider, USA TODAY College, National Review Online and the Washington Free Beacon.