Barcelona has announced it has reached an agreement with Javier Mascherano to extend the player's contract until 2018.
The Argentina international had been the subject of transfer speculation in recent weeks, with Napoli confirming it was keen on securing a deal for the player, who turns 30 on Sunday.
However, Mascherano has now brought talk of a Camp Nou exit to an end by agreeing terms over an improved contract, which will keep him at the club until June 2018 and includes a buyout clause of 100 million euros.
"FC Barcelona announces that it has reached an agreement with Javier Mascherano for the improvement and extension of his contract for the next four years, until 30 June 2018, plus an optional season. His buyout clause will be 100 million euros," a statement released on the club's official website confirmed.
Mascherano, who joined Barcelona from 2010 in Liverpool, has made 184 appearances for the Blaugrana, including 44 in the 2013-14 campaign.
The Argentine, who is currently preparing for the World Cup finals, has won eight major honors with the Catalans, including two Liga titles and the 2011 Champions League.
Speculation had mounted that Mascherano could be offloaded this summer as part of the rebuilding work under new head coach Luis Enrique, who replaced Gerardo Martino at the end of the season.
Reports in Spain suggest Mascherano could be moved back into a midfield role under Luis Enrique next season, having been converted to a central defender by Pep Guardiola and used predominantly in that role by both Tito Vilanova and Martino.