METAIRIE, La. -- Drew Brees has agreed to a two-year deal with the New Orleans Saints that is worth $50 million, sources told ESPN on Tuesday.

The $25 million per year is the same value as the previous deal he signed with the Saints in 2018. The deal is even more team-friendly than last time, considering the inflation of quarterback salaries since then.

The NFL's all-time leader in passing yards and touchdown passes was scheduled to become an unrestricted free agent on Wednesday. But as promised, he didn't even test the open market heading into his 20th NFL season.

It's unclear whether the deal includes voidable years tacked on beyond 2021 -- but that is likely so that the Saints can spread out the salary-cap costs.

Brees, who turned 41 in January, made it clear that he would play only for the Saints after announcing last month that he was planning to come back and "make another run at it."

Still, it was important for New Orleans to get the deal done with Brees before the start of the new league year on Wednesday to avoid being hit with the full $21.3 million salary-cap charge in "dead money" from his previous deal.

That's crucial because the Saints entered this week with less than $10 million in cap space.

The Saints almost certainly can't afford to bring back all three of their quarterbacks from last season, though, as backup Teddy Bridgewater is also an unrestricted free agent and backup Taysom Hill is a restricted free agent.

Bridgewater, 27, is likely to be the odd man out -- especially if he earns an opportunity to start elsewhere after his impressive 5-0 stint in 2019 while Brees was sidelined by a thumb injury.

ESPN's Adam Schefter reported last week that the Saints plan to place a first-round tender on Hill with a qualifying offer of just under $5 million. That means the Saints could match any offer that Hill might sign with another team or receive a first-round draft pick from that team as compensation.

The Saints could also work out a long-term extension instead with the versatile 29-year-old Hill, whom they view as a possible successor to Brees whenever he does retire.

Brees has repeatedly said that he believes he could play at a high level through age 45 -- but only if he wants to keep playing that long. He has been taking that decision "year by year" for the past several years now.

In the meantime, Brees has also agreed to be paid "year by year" with a series of contracts that guarantee him only one year of salary at a time. The last time he was a free agent in 2018, he also accepted slightly less than market value with a two-year, $50 million contract that included just $27 million guaranteed.

Since then, Brees has broken Peyton Manning's NFL records for both career passing yards (77,416 and counting) and career passing TDs (547 and counting). And he has actually posted the two best passer ratings of his career (116.3 in 2019 and 115.7 in 2018).

Brees and the Saints had a disappointing finish last season with a wild-card playoff loss to the Minnesota Vikings after a 13-3 regular season. Brees threw for just 208 yards with one touchdown, one interception and one lost fumble in that game.

However, Brees was playing some of the best football of his career before that, despite the thumb injury. He was named the NFC's Offensive Player of the Month for December, when he threw 15 touchdowns with zero turnovers and completed a NFL-record 29 of 30 passes in a Week 15 win over the Indianapolis Colts.

Saints coach Sean Payton said in late January that it's hard for him to see any drop-off in Brees' performance.

"I'm watching this guy perform, and again his numbers this year exceeded last year's. The job is for him to win, and he's done that," Payton said. "Look, is the ball going down the field the same way? Maybe it's not. And yet his yards per completion and all those things have been real good."

Brees said late last season that when you combine that efficiency with "all the experience and wisdom, I think that just allows you to maintain your prime for longer and longer."

"I really do feel like I should be better every week and every year," Brees said.