SAN FRANCISCO (CBS SF) — Former San Francisco 49ers top draft pick Alex Smith, who staged one of the most remarkable recoveries in NFL history from a gruesome knee injury, took to social media Monday to announce his retirement from professional football.

Smith was traded from Kansas City to Washington in 2018 and during his first season suffered a life-threatening injury to his right leg. When his surgically repaired leg became badly infected, doctors gave him little chance of saving the leg from amputation let alone of ever returning to the gridiron.

But after months of intensive physical therapy, including a stint in a special military rehab clinic, Smith did return to the practice field and in 2020 became Washington’s starter midway through the season, leading the team to an NFC East division title. For his play, he earned accolades as the NFL Comeback Player of the Year.

“Two years ago I was stuck in a wheelchair, staring down at my mangled leg, wondering if I would ever be able to go on a walk again or play with my kids in the yard,” Smith said on an Instagram post.

“On a routine play, I almost lost everything. But football wouldn’t let me give up. Because, no, this isn’t just a game. It’s not just what happens between those white lines on a Sunday afternoon.”

“It’s about the challenges and the commitment they require,” he added. “It’s about how hard and how far you can push yourself. It’s about the bond between those 53 guys in the locker room and everybody else in the organization. It’s about fully committing yourself to something bigger.”

Smith was taken as the first overall pick in the 2005 NFL draft by the 49ers and played with San Francisco from 2005 to 2012.

However, he had the unfortunate fate to play alongside two rising young quarterbacks — Colin Kaepernick in San Francisco and then Patrick Mahomes in Kansas City.

Smith was a three-time Pro Bowler. He finished his career with 35,650 career passing yards, tossing 199 touchdown passes.

In a salary-cap move, Washington released Smith last month with two years remaining on his contract — a move that saved the team $14.9 million against the cap.