"The new deal means that the Barca midfielder will be staying at the club until at least 30 June 2014, four years more than his original contract which was due to run out in 2010," the club said in a statement.
His buyout clause has been set at 80 million euros ($A162.61 million), Barcelona said in a statement.
It did not mention the player's salary, but Spanish media have said the 28-year-old stands to earn 7.5 million euros ($A15.64 million) a year.
A product of Barcelona's youth system, he has spent all of his footballing life at the club since the age of 11.
The player, popularly known as Xavi, was named by UEFA in June as Best Player of Euro 2008, after Spain won their first major trophy in 44 years by defeating Germany 1-0 in the tournament final.
He now has 69 caps for Spain.