Ante Rebic ruined Jupp Heynckes’ farewell as Bayern Munich coach on Saturday with the Croatia striker scoring twice as Eintracht Frankfurt claimed an upset 3-1 win in the German Cup final.

The victory gave Eintracht boss Niko Kovac his first trophy as a coach in his final match before leaving to take over from Heynckes at Bayern.

After Rebic’s opening goal, Robert Lewandowski equalised for Munich early in the second half.

However, Rebic added his late second before substitute Mijat Gacinovic tapped into an empty net just before the whistle to delight Frankfurt fans and break Bayern’s hearts.

This was supposed to be Heynckes’ farewell party with Bayern sending their 73-year-old head coach into retirement with the German cup and league double having wrapped up a sixth straight Bundesliga title.

Instead Rebic and Frankfurt grabbed the glory at Berlin’s Olympic Stadium.

Bayern made a bright start in the capital when Lewandowski hit the underside of the Frankfurt bar with just eight minutes gone.

However, Frankfurt scored from their first clear chance.

When Bayern midfielder James Rodriguez was robbed of possession in midfield, Kevin-Prince Boateng threaded a pass through to Rebic.

The Croatia striker dodged the challenges of Bayern centre-backs Niklas Suele and Mats Hummels to plant his shot past Bayern keeper Sven Ulreich with 11 minutes gone.

The shock goal sent a ripple of panic through the Bayern ranks as it was the third straight game they have fallen behind.

Bayern went close with 25 minutes gone when Lewandowski fired wide of the empty goal after Franck Ribery and Thomas Mueller had already opened up the Eintracht defence.

It should have been 2-0 to Eintracht eight minutes before half-time when Rebic squared for Jonathan De Guzman, who was unmarked, but the midfielder stumbled with the goal at his mercy.

Keenly-fought contest

Tempers started to fray as Frankfurt defender Jetro Willems was booked for body-checking Joshua Kimmich but it stayed 1-0 at the break.

Bayern drew level on 53 minutes when Suele combined with Kimmich, who picked out Lewandowski near the penalty spot to slot home the equaliser.

However, Frankfurt – and Rebic – were not to be denied.

The Croatia international burst in between Suele and Hummels and brilliantly lifted the ball over Ulreich.

The referee checked the replay on advice of the video assistant referee, but the goal stood to make it 2-1 on 82 minutes.

Bayern had calls for a penalty after a foul on Javi Martinez deep into added time turned down.

With all Munich players in the Eintracht half, Frankfurtsealed the victory when Gacinovic got on the end of a Bayern corner, sprinted the length of the pitch to slot into an empty net in the 96th minute.

The Eintracht squad mobbed the 23-year-old and the referee blew the whistle to trigger the Frankfurt party.