A furious second-half comeback by the Patriots — capped off by a 31-yard field goal from Stephen Gostkowski with 2:21 left in overtime — allowed New England to pull off the 34-31 win over the Broncos Sunday night at a chilly Gillette Stadium.

The Patriots, who trailed 17-0 at the end of the first quarter and 24-0 at halftime, posted 21 third-quarter points — thanks to a pair of touchdown passes from Brady and a 1-yard run from Brandon Bolden — on the way to a 31-24 fourth-quarter lead. After a late drive from Peyton Manning drive knotted the game at 31, both quarterbacks had a chance down the stretch, but neither could convert, forcing the game to overtime.

Neither team was able to punch the ball in through the early going in the extra session, but after a Patriots punt with just over three minutes left in overtime, Denver’s Tony Carter — a former New England defensive back — accidentally touched the ball on a punt return, and the Patriots recovered the fumble. That set the stage for Gostkowski’s game-winner.

Brady ended up going 34-for-50 with 344 yards and three touchdowns, while Julian Edelman had nine catches for 110 yards and two touchdowns. Rob Gronkowski had seven catches for 90 yards and a touchdown, while Shane Vereen had eight catches for 60 yards.

On the other side of the ball, Peyton Manning finished 19-for-36 for 150 yards, two touchdowns and a pick, while Knowshon Moreno had 37 carries for 224 yards and one touchdown, while Wes Welker, in his return to Foxboro, had four catches for 31 yards.