At the end of the programme, Lineker was presented with a commemorative cap and golden boot by pundits Alan Shearer and Micah Richards, who were alongside him.
"It's been an absolute privilege to have hosted Match of the Day for a quarter of a century. It's been utterly joyous," he said, thanking the whole production team.
Speaking directly into the camera to viewers at home, he added: "And my final thank you goes to all of you.
"Thank you for watching, thank you for all your love and support over the years.
"It's been so special, and I'm sorry that your team was always on last. Time to say goodbye."