Kyle Terada-USA TODAY Sports

Christian McCaffrey rushed for the tiebreaking touchdown and the San Francisco 49ers went on to a 19-12 victory over the Dallas Cowboys on Sunday in Santa Clara, Calif., to advance to the NFC Championship Game.

Robbie Gould kicked four field goals and rookie Brock Purdy completed 19 of 29 passes for 214 yards as the second-seeded 49ers won their 12th consecutive game. George Kittle caught five passes for 95 yards for San Francisco, which eliminated Dallas from the postseason for the second straight year.

Dak Prescott was 23-of-37 passing for 206 yards, one touchdown and two interceptions for the Cowboys. Prescott tied for the regular-season high of 15 interceptions before tacking on more miscues against the 49ers.

San Francisco will visit the top-seeded Philadelphia Eagles in next Sunday's NFC title game. It is the 49ers' third appearance in the past four seasons.

Deommodore Lenoir and Fred Warner had the interceptions for San Francisco.

CeeDee Lamb had 10 receptions for 117 yards for the fifth-seeded Cowboys.

Dallas lost running back Tony Pollard to a left ankle injury late in the second quarter. He was carted off the field.

McCaffrey's 2-yard touchdown run on the first play of the fourth quarter capped a 10-play, 91-yard drive and gave the 49ers a 16-9 lead.

Brett Maher booted a 43-yard field goal to move the Cowboys within four with 11:03 to play.

Gould kicked a 28-yard field goal with 3:04 remaining to restore the seven-point advantage.

Dallas was unable to threaten on its final drive before time ran out on its season.

Gould kicked three first-half goals to give San Francisco a 9-6 halftime lead.

Lenoir's interception of Prescott set up Gould's 26-yard field goal with 2:12 left in the opening quarter.

Dallas took a 6-3 lead on Prescott's 4-yard pass to Dalton Schultz with 9:25 remaining in the second quarter. San Francisco's Samson Ebukam used his left hand to block Maher's extra point, his fifth such miss this postseason, one shy of the career playoff record held by Roy Gerela (1969-79).

Gould booted a 47-yard field goal to tie the score with 3:43 left. Warner intercepted Prescott at the 49ers' 12 with 1:15 left and San Francisco took advantage with Gould's 50-yard kick as time expired in the half.

Ray-Ray McCloud fumbled on a punt return early in the third quarter and Dallas' Damone Clark recovered at the San Francisco 21. The Cowboys cashed in when Maher sent a 25-yard field goal through the middle of the uprights to tie it at 9 with 9:08 remaining in the third quarter.

More must-reads:

TODAY'S BEST
Patriots' Drake Maye starts OTAs in surprising position
Bettors are buying Bronny James hype before the 2024 NBA Draft
Mets release veteran infielder
Anderson Silva, Chael Sonnen will finish off their trilogy in a boxing ring
Victor Wembanyama, Chet Holmgren highlight 2023-24 All-Rookie team
Jaguars' Doug Pederson discusses Trevor Lawrence contract extension
Saints, star CB 'moving forward' following trade chatter
Pacers ride historic shooting performance to Game 7 blowout of Knicks
Timberwolves mount incredible second-half comeback to stun Nuggets in Game 7
Xander Schauffele proves doubters wrong with historic win at 2024 PGA Championship
Four things we learned from Joey Logano's All-Star Race win at North Wilkesboro
Phil Foden lifts Manchester City to fourth consecutive English Premier League title
Watch: Aaron Judge blasts 13th home run in Yankees' seventh straight win
Canucks won't have linchpin forward for Game 7 vs. Oilers
Jags reportedly mulling extension for Trevor Lawrence, but is that the right choice?
Gordon Hayward calls role with Thunder 'frustrating'
Mets reliever Edwin Diaz showing short shelf life of closers
Three offseason moves the 49ers must make
Watch: NASCAR drivers exchange punches after crash in All-Star Race
Knicks star offers passionate defense of HC Tom Thibodeau after Game 7 loss

Want more sports news?

Join the hundreds of thousands of fans who start their day with Yardbarker's Morning Bark, the best newsletter in sports.