Under contract until 2018, Lahm announced his plan to quit ahead of schedule in the wake of Tuesday’s 1-0 DFB-Pokal win over Wolfsburg, having celebrated his 500th club appearance against Schalke on Saturday.
"I will retire at the end of the season," the 33-year-old confirmed to reporters when asked about his future.
Bayern were keen to name Lahm as the club's new sporting director ahead of next season, but the right-back has opted to take a sabbatical instead.
"I have decided that it is not the right moment yet to take the job as sporting director," he added.
Lahm came through the ranks of the Bayern youth academy and spent his entire career bar a two-year loan with Stuttgart at the Allianz Arena.
He has won seven Bundesliga titles, six DFB-Pokals, the Champions League and the Club World Cup with Bayern.