Xavi will, however, continue to play football at club level.
Spanish midfielder, Xavi Hernadez, has retired from international football at the age of 34.
The Barcelona player represented his country 133 times, a record for a Spanish outfield player, and only bettered by goalkeeper and captain, Iker Casillas.
He defined the nation’s successful ‘tiki-taka’ possession-based playing style and was a key figure in Spain’s glittering run when they won the 2010 World Cup and the 2008 and 2012 European Championships.
Xavi had a disappointing 2013-14 season when Barca failed to win a major silverware for the first time in six years.
Also, holders Spain were knocked out of the World Cup in the group stage.
There were reports that suggested he was poised to end his career in the Middle East or the United States.
However, he has decided to play on at Barcelona under new coach and former team mate, Luis Enrique.
His retirement is coming just before Spain will begin their qualifying campaign for Euro 2016.
“I’m grateful for all those years,” Xavi said at a news conference after a Barca training session.
“I would like to single out Luis Enrique, who has made me see that I can still be important.”
Xavi, who has won three Champions League crowns, seven La Liga titles and a host of other trophies with Barca, made his debut for Spain in a friendly against the Netherlands in November 2000.