Stevens will lead the franchise's search for its next head coach, with Los Angeles Lakers assistant Jason Kidd and former Atlanta Hawks bench boss Lloyd Pierce among those being considered, sources told Yahoo's Chris Haynes.
The 44-year-old Stevens penned a contract extension with the Celtics ahead of last season's bubble in Florida. Boston hired Stevens in 2013 following his back-to-back NCAA Tournament finals appearances with Butler.
In eight seasons with the Celtics, Stevens has guided the team to seven playoff appearances and three trips to the Eastern Conference finals.
"I do think I have a good insight into our team as Danny now steps away," Stevens told ESPN's Tim Bontemps. "I feel like I've got a good idea of what we do well, what we don't do so well, and I've been doing this for eight years. I've been in that locker room with some of those guys for a long time."
Ainge, 62, joined the Celtics front office in 2003 and was named the NBA Executive of the Year in 2008 after constructing the team that beat the Los Angeles Lakers in the 2007-08 NBA Finals.
"Danny has made all the difference over the past 18 years - our record of winning percentage and playoff victories is near the top of the league during that time," Celtics co-owner Wyc Grousbeck said. "He has always been a relentless competitor and a winner.
"Red Auerbach told us Danny is 'lucky,' and he was right, but a lot of the luck came from his intense drive and his incredible basketball insights."
A two-time NBA champion as a player with Boston, Ainge has faced criticism for his hesitancy at the trade deadline. This year's moves for Evan Fournier, Mo Wagner, and Luke Kornet were the first in-season trades the team made since acquiring Isaiah Thomas from the Phoenix Suns in 2015.
The Celtics qualified for the playoffs in all but three of 18 seasons under Ainge's watch, and they progressed to the Eastern Conference finals on seven occasions and NBA Finals twice.
News of Ainge's retirement comes a day after the Celtics were eliminated in five games in the first round by the Brooklyn Nets.
The Celtics have $135.9 million committed to 12 player slots - $140.9 million if Jayson Tatum gets an All-NBA nod, as per his contractual bonuses. That's right around the projected luxury tax of $136.6 million for the 2021-22 season.
Boston's ability to target relatively big names in free agency is limited due to the contracts of Tatum, Jaylen Brown, and Kemba Walker. A decision also has to be made on Fournier, who becomes an unrestricted free agent with Bird rights, which permits the team to resign him regardless of cap space.