The move was retroactive to Wednesday.
The Marlins also recalled left-hander Dan Jennings from Triple-A New Orleans.
Alvarez, who was scheduled to start Sunday game against Cincinnati, was named to the All-Star team this season for the first time in his career. He's 8-5 with three shutouts and a 2.48 ERA.
Alvarez pitched seven scoreless innings Tuesday in a 3-0 victory over Washington. He showed some discomfort in the second inning, but stayed in the game after manager Mike Redmond and trainers tended to him.
Jacob Turner, who was briefly moved to the bullpen in place of Cosart, will start Sunday in Alvarez's spot.