The North Carolina wide receiver returned the opening kickoff for a touchdown, threw for another on a trick play and hauled in the eventual go-ahead score midway through the fourth quarter as the Tar Heels ended a six-game losing streak with a 34-31 victory over Pittsburgh on Thursday.

"It's been too long," North Carolina quarterback Nathan Elliott said. "We haven't had that feeling in a long time. You walk in the locker room, you think we're 12-0."

Not exactly. Though it doesn't seem to matter where the Tar Heels (2-8, 1-6 Atlantic Coast Conference) are at when they face the Panthers. North Carolina is 5-0 against Pitt since the Panthers joined the ACC in 2013.

Last season, the Tar Heels needed a touchdown throw on the final snap to hold off Pitt. This time, the deciding score came a bit sooner. Ratliff-Williams hauled in a 3-yard flip from Elliott with 6:18 left to bookend an electric night for the sophomore wide receiver.

Ratliff-Williams accounted for 230 all-purpose yards for the Tar Heels. He ran through a sea of arm tackles 98 yards to the end zone on the opening kickoff, floated a 35-yard score to Josh Cabrera in the second quarter before catching Elliott's second touchdown pass as North Carolina beat a Power Five conference team for the first time in 369 days.

"You go on the road in the ACC and win here, that's a tough thing to do," Tar Heels coach Larry Fedora said. "I'm proud of those guys. It's something they can build off of. The staff and the seniors have done a great job of keeping them close and keeping them believing. Good things are starting to happen."

Nathan Elliott completed 20 of 31 passes for 235 yards and two scores in his first start.

"He did exactly what Nathan Elliott can do," Fedora said. "He's been such a great teammate, biding his time, working his butt off, never saying a word, waiting for his opportunity and when his opportunity has come up, he's made something out of it."

Darrin Hall ran for 121 yards and four touchdowns for Pitt (4-6, 2-4), but the Panthers saw their modest two-game winning streak come to an end and now face an uphill battle if they want to lock down a bowl berth for a 10th consecutive year. Pitt finishes the regular season against No. 17 Virginia Tech and No. 7 Miami.

"I don't really know how to explain it," Panthers coach Pat Narduzzi said. "We talk all the time about taking it. We found a way to give it away."

PIVOTAL PLAY

The Panthers appeared ready to move in front late in the first half when wide receiver Quadree Henderson darted for the pylon on a jet sweep. Instead, North Carolina's J.K. Britt stripped Henderson before he crossed the goal line . Linebacker Cayson Collins scooped it up and raced 64 yards. Freeman Jones hit a career-best 51-yard field goal to give the Tar Heels a 24-17 lead going into the break.

"That's a 10-point swing," Fedora said. "That's a huge play in the game."

PLAYING KEEPAWAY

Elliott wasn't told he was starting until Wednesday, but Fedora made one simple plea to an offense that had committed 20 turnovers coming in: hold on to the ball. The Tar Heels did and rolled up 366 total yards. North Carolina also did something it has struggled with all season, finishing off an opponent. Pitt punted with 2:54 left and North Carolina ran out the clock.

"We said if it was 10:30 at night and we didn't turn the ball over we'd be happy," Fedora said. "That's what (Elliott) did, he took care of the football."

HUGE HALL

Hall has effectively put the starting running back spot on lock down. His four touchdowns were the most by a Panther since James Conner scored four times in a loss to the Tar Heels in 2014. Hall has gone over 100 yards in each of his last three games.

THE TAKEAWAY

UNC: Elliott likely deserves another look. The sophomore needs work as a passer but his mobility kept Pitt's improved pass rush in check for long stretches. He was at his best late while leading the Tar Heels on the late drive that put them ahead to stay.

Pitt: The Panthers are going to need something miraculous to keep their bowl streak alive. Virginia Tech and Miami will both have something significant to play for and Pitt will need to win both if it wants to extend its' season beyond the day after Thanksgiving.

UP NEXT

UNC: Welcomes Western Carolina to Chapel Hill on Nov. 18.

Pitt: travels to No. 17 Virginia Tech on Nov. 18.

---

More AP college football: http://collegefootball.ap.org and https://twitter.com/AP-Top25