CHAPEL HILL, N.C. -- Jacory Harris passed for 267 yards and three touchdowns to help Miami beat North Carolina 30-24 on Saturday.

The Hurricanes (3-3, 1-2 Atlantic Coast Conference) nearly lost a 24-point lead, surviving a sluggish second half for their first road win under Al Golden.

Miami, which gained 263 of its 311 total yards in the first half, avoided the first 0-3 start in league play in program history. The Hurricanes also picked up their first win in five tries at North Carolina.

Bryn Renner passed for 288 yards and two touchdowns for the Tar Heels (5-2, 1-2), who trailed 27-3 late in the second quarter.

Giovani Bernard rushed for 110 yards and a touchdown, becoming the first North Carolina player to rush for at least 100 yards in five consecutive games since Ethan Horton in 1984.

The Tar Heels scored two fourth-quarter touchdowns, cutting Miami's lead to 30-24 on a 20-yard catch by Reggie Wilkins with 46 seconds remaining. Curtis Campbell recovered the onside kick for North Carolina after Miami's LaRon Byrd was unable to secure the ball.

North Carolina moved the ball to Miami's 30 before Sean Spence sacked Renner. The Tar Heels had a final play from the Miami 37, but a pass to Bernard with laterals to Erik Highsmith and Jheranie Boyd was stopped after a 13-yard gain.

Miami's Lamar Miller entered the game as the ACC's leading rusher, but his streak of five consecutive 100-yard games ended. He managed just 29 yards on 16 carries.

Miami found other ways to move the ball, jumping on the Tar Heels for a 17-0 lead after one quarter. North Carolina had outscored its opponents by a combined margin of 42-3 in the first quarter before the Hurricanes rolled into town.

Miami led 14-0 before its defense ever took the field.

Harris marched the Hurricanes 71 yards for a touchdown on the game's opening drive, capping the 13-play series with a 4-yard scoring pass to Mike James.

North Carolina's T.J. Thorpe lost a fumble on the ensuing kickoff, setting up the Hurricanes on the UNC 27. Harris found Tommy Streeter, who got open deep after an end-around fake to Benjamin, on the next play for a touchdown.

After North Carolina's Thomas Moore kicked a 20-yard field goal to cut Miami's lead to 17-3, the Hurricanes answered with a field goal of their own.

Then they capitalized after a 13-yard punt by North Carolina's Thomas Hibbard gave them the ball at UNC's 40. Harris connected with Benjamin on a deep pass down the right sideline for a 30-yard touchdown and a 27-3 advantage.

Criticized heavily throughout his career for being turnover-prone, Harris finished without an interception for the third consecutive game. Before he took a knee to close out the first half, Harris had led the Hurricanes to points on 10 of their last 11 possessions dating to their 38-35 loss at Virginia Tech last week.