Joaquin, who will be 32 next month, began his professional career at Real Betis and joined Malaga in 2011 after a five-year stint at Valencia.
He became a firm favourite with the fans and scored several vital goals on the Qatar-owned club's run to the last eight of the Champions League last season.
Neither club disclosed financial details of the deal but Joaquin is valued at 3.5 million euros on website Transfermarkt.com, which tracks football transfers.
"Malaga would like to thank Joaquin for his dedication, professionalism and commitment to the club and wish him good luck in his first professional experience outside Spain," the club said on their website.
Fiorentina finished fourth in Serie A last season and qualified for the Europa League, the continent's second-tier club competition.
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.