Mr. Massey beat Democrat Bill Clyburn by 138 votes in a recount Thursday, according to the state Election Commission.
Votes were recounted because the winning margin was within 1 percent.
"I'm excited, and I'm ready to get to work," Mr. Massey said.
Mr. Clyburn called to congratulate Mr. Massey after learning the final count.
At a meeting of the South Carolina legislative delegation and the Aiken County school board, Mr. Clyburn thanked his supporters.
"I will be returning to Columbia to work with Mr. Massey," he said. "I feel good about running a clean campaign, and I think young people will feel more inclined to participate in the election process now."
Mr. Massey, an Edgefield resident, approached his first campaign as a grass-roots effort, knocking on doors throughout the community.
"It was a lot of hard work, but I really enjoyed it," he said. "Getting to meet people and listening to what their concerns are, there's no substitute for that, just old-fashioned politics."
Mr. Massey will continue practicing law in Aiken County, but plans to make being a senator his priority once the legislative session begins in January.
He said he will continue to work with Mr. Clyburn, who serves in the state House of Representatives.
"He's a real class act, and he's a great guy," Mr. Massey said. "I'm eager to work with Rep. Clyburn and other members of the delegation so we can get some things done for the people of our district and the state of South Carolina."
Reach Julia Sellers at (803) 648-1395, ext. 106, or email@example.com.