Thiago Alcantara got the winner as Bayern Munich continued to ease the pressure on coach Niko Kovac with a Bundesliga win at Mainz on Saturday.

Champions Bayern cut the gap to leaders Borussia Dortmund but were far from impressive in their 2-1 victory at Mainz 05 as they made it three wins in three matches in all competitions following their early-season dip in form.

Leon Goretzka put the visitors ahead in the 39th minute after an earlier effort by Thiago Alcantara was ruled out following the use of the video assistant referee.

Goretzka’s volley put the visitors ahead after a sustained period of attacking pressure but Bayern’s defensive frailties were exposed by a fast Mainz break and a Jean-Paul Boetius goal just after half-time.

Mainz did not have to wait long for an equaliser, with Jean-Paul Boetius striding into the box in the 48th to drill in a cross after being left completely unmarked.

Spaniard Thiago got his goal in the 62nd minute to put Bayern back in front and Javi Martinez hit the woodwork a little later as Bayern hung on to their slim lead and the three points.

Bayern, who have been under pressure after a dip in form early in the season, lacked a clear game plan, especially in attack, and never really hit top speed against lowly Mainz.

The champions are now on 19 points in second place, two behind Dortmund, who drew 2-2 against Hertha Berlin.

The Bavarians have now won all three games in all competitions since club bosses launched a verbal attack on the media last week, blaming them for what they said was unfair reporting during their four-game winless run.

Bayern Munich secured back-to-back league victories for the first time since September as Thiago Alcantara scored the winner against Mainz.

A draw would have been a disappointing result for Kovac’s men, who went into the game trailing league leaders Borussia Dortmund by four points, but Thiago’s first league goal of the season helped them to a third successive win in all competitions.

The hosts set their stall out to defend and packed their penalty area but Joshua Kimmich shook the frame of the goal after 26 minutes when he sent a swerving drive onto the crossbar.

After VAR was used to rule out a Thiago close-range volley that found the net through a crowded box, Bayern opened the scoring on 39 minutes when Kimmich’s neat cross from the right was volleyed home smartly by Goretzka from 10 yards out.

Within three minutes of the restart Mainz were level, Daniel Brosinski’s cross from the right reaching the far post where Boetius shrugged off Kimmich before beating Manuel Neuer low to the goalkeeper’s left with a side-footed finish.

Robert Lewandowski scampered down the right side of the penalty area and whipped in a low cross that found Thiago, who slid in and guided the ball into the left corner of the net to allow the visitors, their coach and their supporters to breathe a sigh of relief.

Bayern must travel north to face Regionalliga side Rodinghausen in the DFB-Pokal, while Mainz face the rather more difficult task of a cup game away at Augsburg.

Bayern Munich’s hero of the day Thiago Alcantara raises his fist as his teammates hug him in celebration for scoring the goal against Mainz at Opel Arena, Mainz on Saturday.