Fifty-one weeks ago at the Mercedes-Benz Superdome, San Francisco 49ers linebacker Ahmad Brooks appeared to have sealed a victory against the New Orleans Saints by causing a turnover with a controversial clothes-line sack of quarterback Drew Brees.

Instead, officials flagged Brooks for roughing the passer and returned the ball to the Saints, who eventually prevailed 23-20 on a field goal as time expired.

Brooks again found the spotlight Sunday at the Superdome; but this time, he helped the opportunistic Niners escape with a potentially season-saving 27-24 victory in overtime before a sellout crowd of 73,129.

With 5:18 left, Brooks and undrafted rookie linebacker Chris Borland combined on a sack, strip and fumble recovery at the Saints’ 17. Brooks received credit for the sack and strip, while Borland outwrestled Saints running back Travaris Cadet for the loose ball to go along with his game-high 17 tackles.

Replay official Dale Hamer confirmed the fumble ruling on the field. Moments later, as fans streamed to the exits, 49ers kicker Phil Dawson made it official with a 35-yard field goal.

“The officials got it right this time,’’ Niners defensive coordinator Vic Fangio said after the 49ers snapped a two-game losing streak and improved to 5-4. “It was poetic justice that the game ended that way based on what happened last year.’’

The game ended for Brees much like it started: with a turnover that resulted in points for the visitors.

On the third play from scrimmage. 49ers strong safety Antoine Bethea returned an interception 22 yards to the Saints 19. Barely two minutes into the game, running back Frank Gore gave San Francisco a 7-0 lead on a 4-yard scoring run.

A second Brees interception at the goal line thwarted a Saints scoring opportunity just before halftime. But the third Brees turnover enabled the Niners to snap New Orleans’ club-record home winning streak at 11 games, 19 with coach Sean Payton on the sideline.

Facing a second-and-15 at the Saints’ 15, Brees called for the ball from shotgun formation in an empty backfield. That personnel package allowed Brooks to work one-on-one against Saints second-year left tackle Terron Armstead.

With his vertical receivers covered down field, Brees went to check down to Cadet. But Cadet had slipped down, giving Brooks an extra tick or two to get around Armstead and reach the target.

“Yeah, I was really surprised,’’ Brooks said. “When I was rushing, I was thinking to myself, ‘Is he going to throw the ball yet?’ But he didn’t.

“My hats off to the secondary. They was covering them boys and we were able to get to the quarterback. That was a team play. That wasn’t just me.’’

Though hit six times and pressured on numerous other plays, Brees avoided being sacked until the Saints’ final two plays from scrimmage ... in overtime, with the outcome resting in the balance.

“We had been getting decent pressure on Brees pretty much all day,’’ Niners defensive tackle Justin Smith said. “That’s why you know his name. He’ll make some plays, and he did today.

“They didn’t have to win, but it was a must-win for us. Luckily for us, we got it.’’

Or, in the words of Brooks, the football gods “smiled down on us.’’