The new deal ties Bartra to Barca until June 2017 and the 23-year-old will put pen to paper on the contract in the coming weeks, the Primera Division champions have announced.
A Barca statement read: "Barcelona announce they have reached an agreement with Marc Bartra to renew his contract, which finished next June 30, and which will be extended until June 30, 2017.
"The buy-out clause in the new contract will be 25 million euros (£20.7million)."
Bartra, who turned 23 today, has started 10 matches for Barca in all competitions this season, with four more appearances off the bench. Last season he featured in 16 matches in the whole campaign.
The Catalan-born centre-back was briefly on the books at Espanyol as a youngster before making the cross-city switch to the Nou Camp and, after progressing through the youth ranks, he made his first-team debut for Barca as a 19-year-old against Atletico Madrid in February 2010.
At international level, he has represented Spain at Under-18, U19, U20 and U21 age groups before making his senior debut in the friendly win over Equatorial Guinea in November,
Bartra is the latest in a long line of Barca players to commit their futures to the club, with the likes of Lionel Messi, Xavi, Carles Puyol and Andres Iniesta all agreeing new deals in the last year.