Lionel Messi will be leaving Barcelona because of "financial and structural obstacles", the club announced.
There were reports earlier that Barcelona and Messi had come to a verbal agreement after the Argentinian star agreed to take a pay cut, and that a new contract will soon be signed.
But Barcelona's announcement put an end to all speculations and hopes of Barca fans that the iconic player will stay put at the club which he joined at 13 and had played for ever since.
"Despite FC Barcelona and Lionel Messi having reached an agreement and the clear intention of both parties to sign a new contract today, this cannot happen because of financial and structural obstacles (Spanish Liga regulations)," the club said in a statement.
"As a result of this situation, Messi shall not be staying on at FC Barcelona. Both parties deeply regret that the wishes of the player and the club will ultimately not be fulfilled.
Messi, who led Argentina to Copa America title on July 10, has been a free agent since July 1 after his contract with Barcelona expired.
"FC Barcelona wholeheartedly expresses its gratitude to the player for his contribution to the aggrandisement of the club and wishes him all the very best for the future in his personal and professional life."
Barcelona's finances suffered a huge blow last season, when the questionable management by the prior club board was exacerbated by a drop in revenues provoked by the pandemic.
When Joan Laporta returned as president, he inherited a club saddled with debt of 1.2 billion euros ($1.4 billion) and massive contracts that former club president Josep Bartomeu gave players, including Messi.
Messi's previous contract, signed in 2017, earned him an eye-popping 138 million euros ($164 million) per season.
Laporta had said Barcelona's finances "were worse than I had imagined." He said the payroll plus other payments tallied 650 million euros ($771 million).
The Spanish league slashed the salary cap for Barcelona down from a league-high 671 million euros ($796 million) for the 2019-20 season to just 383 million euros ($454 million) for last campaign.