Messi, 34, has been a free agent since 1 July when his contract expired.
He agreed a new deal on reduced wages with club two weeks later, but it was dependent on Barca selling players to afford his salary.
“Both parties deeply regret that the wishes of the player and the club will ultimately not be fulfilled,” the club said.
Barcelona said Messi was poised to extend his 21-year career with the club by signing the deal on Thursday, and blame La Liga for the failure to do so.
“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 La Liga regulations],” the club said.
“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.”