Lawyers for Mr. Fields, 22, had pleaded for mercy, citing his difficult childhood and mental health problems.

Image Ms. Heyer. Credit... Facebook, via Reuters

Mr. Fields was among hundreds of white supremacists who swarmed Charlottesville in August 2017 for the rally, in which they shouted anti-Semitic phrases, marched with tiki torches and attacked a racially diverse group of counterprotesters. The rally appeared to be winding down when Mr. Fields drove his car into a crowd of those counterprotesters.

The sheer number of white nationalists who marched in Charlottesville, and President Trump’s assertion afterward that bad actors on “many sides” were to blame for the violence, led to a national reckoning on the ascendance of white supremacy and the threats it poses.

Ms. Heyer, 32, a paralegal, was known in Charlottesville as someone who spoke out when she saw injustice.

“Heather was a very strong woman” who stood up against “any type of discrimination,” Alfred A. Wilson, a manager at the law firm where she worked, said shortly after her death. “That’s just how she’s always been.”