COLLEGE STATION, Texas (AP) -Colt McCoy threw four touchdown passes and No. 3 Texas overcame a huge game by Texas A&M quarterback Jerrod Johnson to wrap up an undefeated regular season with a 49-39 win over the Aggies on Thursday night.

The Longhorns (12-0, 8-0 Big 12) have only next week's conference championship game against Nebraska standing between them and the BCS title game.

For a while, though, it seemed as though Johnson would rally the Aggies (6-6, 3-5) to a gigantic upset, shattering McCoy's Heisman Trophy hopes and opening the door for TCU and Cincinnati to vault into the national championship picture.

Jeff Fuller caught three touchdown passes from Johnson, the last with 7:10 left to cut Texas' lead to 42-39. But Marquise Goodwin returned the ensuing kickoff 95 yards for a touchdown, and the Longhorns could finally breathe easy after A&M's Randy Bullock missed a 23-yard field goal try with 3:05 remaining.

McCoy completed 24 of 40 passes for 304 yards and ran for a career-high 175 yards on 18 carries. But Johnson was just as spectacular, completing 26 of 33 passes for 342 yards with four TD passes against the Longhorns' third-ranked defense.

The two quarterbacks embraced at midfield after the game, and Johnson's nationally televised showcase just might put him in the conversation for next year's Heisman.

McCoy is a favorite to win it this year and he put together a monster first half, completing 18 of 26 passes for 222 yards with three TD passes. He also broke a 65-yard run up the middle early in the second quarter, the third longest rush by a Texas quarterback. McCoy had 111 yards rushing by that point, already a single-game career high.

The Longhorns piled up 398 yards by halftime against the nation's 100th-ranked defense, but only led 28-21.

The Aggies took a surprising 7-0 lead on the third offensive play, a 70-yard pass from Johnson down the sideline to Fuller. It was the second-longest play from scrimmage against the Longhorns this season.

Early on, though, the Aggies' defense couldn't get close to McCoy even when they blitzed, and he tied it with a 14-yard touchdown pass to Jordan Shipley with 3:42 left in the first quarter.

The Longhorns' defense, meanwhile, had just as much trouble controlling the quick-footed Johnson, ranked 10th in the nation in total offense (293.9 yards per game) coming into the game.

Johnson threw a 36-yard pass to Ryan Tannehill, then found Fuller open for a 14-yard touchdown with 7:34 left in the first half. It was Johnson's 49th career touchdown pass, an A&M record.

After Texas moved ahead 21-14, Longhorns defensive end Sam Acho sacked Johnson on a third-down play, forcing a punt. Shipley called for a fair catch, but the ball bounced off a teammate and A&M linebacker Anthony Lewis recovered at the Texas 36.

The miscue set up Johnson's 14-yard TD pass to Howard Morrow with 1:11 left in the half. The Longhorns hadn't given up 21 points in a game since a 34-24 win over Texas Tech on Sept. 19.

The Aggies left just enough time for McCoy to answer again. He threw two passes to Shipley for big gains, then found James Kirkendoll for the go-ahead score with 5 seconds left before the break.

Tre Newton had a 7-yard touchdown run, set up by a fumble by A&M running back Christine Michael.

Aggies linebacker Lewis and Texas defensive back Deon Beasley collided on the ensuing kickoff, and both players initially lay motionless. Lewis was helped off the field, but Beasley was put on a stretcher. He was moving one of his arms as he was taken off the field on a cart.

Johnson broke a 43-yard run, but Texas safety Earl Thomas picked off Johnson in the end zone, his school-record eighth interception of the season.

Bullock's 31-yard field goal cut the deficit to 35-24, and the Aggies took over again at midfield as McCoy started to misfire. Johnson completed two passes and Michael spun off a Texas defender for a 16-yard touchdown with 13:38 left. Johnson completed a pass to Tannehill for the 2-point conversion to make it 35-32.

McCoy missed on seven straight passes before hitting Kirkendoll on a slant. Freshman defensive back Steven Terrell couldn't make the tackle and Kirkendoll raced the final 40 yards for a touchdown with 12:04 left.

Just when it seemed as though the Longhorns had put A&M away, Johnson marched the Aggies down the field again. He found freshman Ryan Swope for a 27-yard gain, then lofted a 20-yard pass to Fuller with 7:10 left.

Goodwin then returned the ensuing kickoff all the way for a touchdown, the Longhorns' third kickoff return for a score this season.

The Longhorns were upset by Texas A&M in 2006 and '07, but they've won twice since Mike Sherman replaced Dennis Franchione as Aggies coach. Texas has won 12 of the last 14 meetings against its archrival.

This one, however, will go down as one of the most exciting in the 116-game series.