The midfielder, who played a key role in his country's historic run of three successive major international title triumphs, says "the time has come" for him to walk away
The Real Madrid midfielder was a key component in the side that made history by winning three successive major tournaments: Euro 2008, World Cup 2010 and Euro 2012.
Alonso's Roja career ended on a low, with the country suffering a shock first-round exit at Brazil 2014 this summer, but the 32-year-old insists that he has nothing but found memories of his time with the national team.
"I want to report that I have finished my time with Spain national team," the Basque wrote in an open letter published on Spain's official national team website.
MORE: Alex Morgan upset at 159-degree temps | Transfer photos
"The hardest part is knowing when to say goodbye and, after much thought, I think that time has come.
"I end with a glorious national team career that began over 11 years ago, having been part of a historical generation that has fulfilled the dream of millions of fans, doing something as unique as winning a World Cup and two European Championships in four years.
"Since April 30, 2003, when I made my debut at just 21, I have experienced only good times, so I have only words of thanks to all those with whom I have shared more than a decade.
"I want to thank all my coaches, teammates and the millions of fans who have always shown me kindness and respect.
Inaki Saez, the unforgettable Luis Aragones and Vicente del Bosque are figures that I will always carry with me for having helped me grow professionally and personally.
"I could not list all the colleagues with whom I have shared this shirt, but I want to thank each and every one of them for all you have shown me and taught me during this memorable period of my life.
"Thanks to Real Sociedad, Liverpool and Real Madrid for opening the doors to be part of a single dream. All my clubs have always helped and supported me to make it happen.
"Finally, I want to convey my sincere thanks to the fans. We dream together and share the glory together. We had many unforgettable moments.
"Good luck to all who continue to work and fight for this shirt, with the absolute conviction that they will achieve new successes."