Wagner scored twice in the second half, one from the penalty spot and the other a great volley after Dennis Geiger had given Die Kraichgauer an early lead.
In truth it could have been much more but in the end it was comfortable day at the office for the visitors, while the hosts face a real battle after the international break to turn their season around in the league.
Geiger struck early to give the visitors a deserved lead
In terms of the game itself, straight from the start the visitors looked well up for the game and they took the lead in ninth minute when Geiger controlled Kerem Demirbay's shot before putting the ball into the back of the net at the second attempt.
The goal though didn't put the hosts as they almost responded straight away when a great run from Leonardo Bittencourt saw the midfielder put a shot just wide of the goal with the goalkeeper beaten.
Timo Horn, though, had to be at his best at the other end to stop the visitors from doubling their lead as he denied Nadiem Amiri, Wagner and Mark Uth in quick sucession to keep his side in the game.
Osako came within inches of levelling for the hosts before half-time
These saves were almost crucial as the hosts were so unlucky to not get an equaliser just before half-time when Yuya Osako picked the ball up in midfield before unleashing a good shot from the edge of the box but the ball came back off the post with the keeper beaten.
Therefore, at the break, the visitors were in front but knew they had to score again early in the second half to stop the hosts from gaining any kind of confidence to get back into the game, while the hosts knew that if they could stay in the game they would get more chances.
Wagner made it two for the visitors from the penalty spot
The second half started the same way as the first as the visitors got second goal in the 56th minute from the penalty spot. Referee Deniz Aytekin pointed to the spot after Paweł Olkowski fouled Uth after the striker rounded Horn and was about to put the ball into the net.
Wagner stepped up to take the penalty and he confidently sent the keeper the wrong way to give the visitors exactly what they wanted straight after the break.
The hosts failed to take their chances to get back into the game
After scoring the second goal though the visitors took their foot off the pedal and that allowed the hosts to come back into the game and they almost got a goal back but Olkowski was denied by a good save from Oliver Baumann.
They had an even better chance to get a goal back minutes later when a free-kick from Horn was flicked into the path off Sehrou Guirassy, who was in on goal, but he somehow put his shot well side of goal.
Wagner added a third for the visitors before the end to seal the three points
That miss was punished with ten minutes remaining in the game after a great cross from Andrej Kramarić, on as a second half substitute, found Wagner unmarked at the back post and the striker volleyed the ball home into the back of the net to end the game as a contest.
After the third goal the game drifted until the final whistle as Julian Nagelsmann's men secured a vital three points, while the hosts will have to wait for another week to finally get a win in the league this season.