The UEFA Champions League holders said an agreement had been reached "in principle" for the 27-year-old, who found his place in the Bavarian team taken by Mario Mandzukic last season.
The two clubs had been negotiating over the transfer for some time, with Bayern saying last week the deal was dead, as the Florentine club were reportedly unwilling to meet the German double winners' €20m ($25.7m USD) asking price.
Bayern's communications director, Markus Horwick, said a contract until 2017 should be signed "in the next one to two weeks." Gomez is expected to earn around €4m per season.
Italian newspaper Gazzetta dello Sport claim the transfer will cost Fiorentina €15m.
Gomez was under contract in Munich until 2016, but was known to have become frustrated at his lack of playing time as Mandzukic started the majority of matches under Jupp Heynckes.
He was eager to orchestrate a move abroad in order to get more first-team football, especially with the 2014 FIFA World Cup Brazil™ only a year away.
Despite being benched for most of the campaign, Gomez still managed 19 goals last season, including two in the DFB-Pokal final.
Known as 'Super Mario' after the computer game character, Gomez joined Bayern in 2009 from Stuttgart for €35m. He has scored 25 goals for Germany in 58 appearances.