The Argentine forward has returned to the first-team setup at Upton Park under Slaven Bilic but leaves the club on a permanent basis for another spell in Serie A
Fiorentina have signed Argentine forward Mauro Zarate from West Ham.
The 28-year-old traveled to Florence earlier on Thursday to undergo a medical and has now completed his move to the Serie A side.
"I would like to thank David Sullivan and David Gold for believing in me and for giving me the opportunity of playing at such a special club like West Ham," Zarate said in a farewell message posted on Twitter.