And both clubs, plus a third adidas-sponsored team, will try again for the Argentine at the end of this season.
Adidas are prepared to meet half of Messi's €125 million buyout clause, with the club needing to cover the outstanding fee plus the player's wages demands.
Chelsea and Bayern chiefs believe Messi could be ready to leave Barca in the summer after the departures of Pep Guardiola and Tito Vilanova, plus the haranguing from government officials over his tax problems.
Gallardo says the bid will "shake the foundations of Barca" when it is made at the end of this season.
For breaking stories and all the great banter like us on Facebook: facebook.com/tribalfootball