Charlottesville - Joe Harris scored 19 points, 16 after halftime, and Virginia stretched its winning streak to eight games by beating Maryland 61-53 in the Terrapins' last visit as an ACC rival.
Maryland is moving to the Big Ten after this season.
Malcolm Brogdon added 14 points and Akil Mitchell 13 for the Cavaliers, who improved to 20-and-5 on the season and 11-and-1 in the ACC, continuing their best start in conference play since the '81-82 team opened 12-and-1.
"There's a reason they're 11-1 in the league," Terps coach Mark Turgeon said. "When the game was on the line, their seniors stepped up, made some big plays for them. The defense stepped up." Seth Allen scored 15 points and Dez Wells had 12 for Maryland (14-11, 6-6), which had won three of four.
A huge play in the second half came after a block by Maryland when UVa's Justin Anderson soared at the other end to block a shot by Maryland's Roddy Peters near the rim and save the ball. He started a fast break that moments later was capped by Harris' 3-pointer from the right corner, arousing a crowd that had grown quiet by the tight ballgame.
"Huge momentum swing," Harris said. "That was a big play and that was an unbelievable block."
A dunk by Darion Atkins and Brogdon's 17-footer pushed the lead to 44-35. It was 52-41 with just under 5 minutes to play when the Terps staged a rally, getting seven points from Nick Faust and a basket from Wells in a 9-2 run that brought them within 54-50. But Harris hit the front end off a 1-and-1 with 1:03 to play, Maryland missed at the other end and Harris' two free throws sealed it.
Virginia has now won 11 of its last 12 games and is now off until Saturday's game at Clemson.