Theo Pinson of North Carolina tries to save a loose ball during the ACC semifinals against Duke at Barclays Center. (Al Bello/Getty Images)

North Carolina used a combination of strong perimeter defense and balanced scoring to build a big lead, then fended off a furious rally down the stretch to outlast Duke, 74-69, in the ACC tournament semifinals Friday night.

The No. 6 seed Tar Heels placed five players in double figures and limited their contentious state rival to 6 for 23 from beyond the arc to advance to the conference tournament championship game for the 35th time.

North Carolina will face top-seeded Virginia on Saturday night at Barclays Center, where the Tar Heels are seeking a 19th tournament crown.

North Carolina senior guard Joel Berry II, named most outstanding player in the Final Four last season during the Tar Heels’ march to the national title, knows the Cavaliers are a tall task.

“We’ve just got to make sure we’re taking good shots and making sure we’re moving them on the defensive end. They’re great defensively, and we’ve just got to me sure we limit our mistakes,” said Berry, who had 13 points and six assists with just one turnover in 37 minutes.

“If you make a turnover, you know that you’re going down, and you’re about to play defense for 30 seconds because they keep moving the ball until they get what they want to get.”

Voted most improved player in the ACC this season, junior forward Luke Maye led North Carolina (25-9) with 17 points, 10 rebounds and four assists in 33 minutes.

The Tar Heels had 24 assists on 28 made field goals and forced 18 turnovers that led to 24 points. Second-seeded Duke (26-7), which won this tournament last season, collected just 14 points off 13 North Carolina turnovers and shot just 40.7 percent (22 of 54) for the game.

“It was really physical game,” Duke Coach Mike Krzyzewski said. “Congratulations to North Carolina. Kind of a disjointed game. It’s kind of a weird game tonight, but the turnovers hurt us, and their offensive rebounds. We’re not going to win a game against a team of that caliber if we turn it over 18 times.”

Duke got within 72-69 in the closing minute on Gary Trent Jr.’s three-pointer, but Theo Pinson made two free throws with three seconds to play to seal the triumph.

“I thought for a big stretch in the second half we were really, really good,” North Carolina Coach Roy Williams said. “We were making shots. We were defending. Then all of a sudden from the five-minute mark, we have five turnovers. Thank goodness when we missed a bunch of shots, we also go the rebound. The bottom is we made enough plays, and we’re still playing.”

In front by five at halftime, North Carolina stretched the lead to 56-43 with 12:02 to go in the second half thanks to a push featuring a two free throws by Berry, Sterling Manley’s dunk and a layup from Pinson. Maye also fueled the charge with a jumper and tip-in.

Marvin Bagley III had 19 points and 13 rebounds for the Blue Devils, and Trent added 20 points and six rebounds. Bagley, a projected NBA lottery pick, was named ACC player and rookie of the year, becoming the second player in conference history to win both awards in the same season.

A knee injury to Bagley late in the season proved somewhat of a turning point for Duke, which won each of the four games he missed. During that time, Grayson Allen averaged more than 20 points, getting more shots near the rim with the painted area less cluttered.

But the Blue Devils also thrived defensively while Bagley was on the mend, holding four straight opponents in the 50s or fewer for the first time in the program’s storied history.

Since Bagley rejoined the line on Feb. 24 against Syracuse, Duke won three of four entering the ACC tournament semifinals and had the look of a national championship contender and perhaps remains in line to be a No. 1 seed when the NCAA tournament’s field of 68 is unveiled on Sunday.

The Tar Heels, meanwhile, limped into the ACC tournament with two straight losses, including the annual regular season finale Duke, 74-64, on March 3 at Cameron Indoor Stadium. North Carolina led that game by double figures at halftime.

Playing in the ACC tournament for the first time as a sixth seed, North Carolina opened a 34-27 lead against the Blue Devils on Saturday with 52 seconds left in the first half on a pair of free throws from Garrison Brooks.

Those points followed a flagrant foul assessed to Allen for sticking his backside out and clipping the Tar Heels freshman forward.

Brooks fell hard onto the court, and officials reviewed the sequence via replay before making their ruling that drew jeers from North Carolina supporters with little patience for Allen, whose similar antics throughout his career have infuriated opponents and their fan bases alike.