Julian Brandt's opener had put the tournament favourites ahead, though a Djigui Diarra penalty save and Souleymane Coulibaly header levelled things up, leaving the sides level for an hour. Niklas Stark then fired the crucial spot-kick wide and sent Fanyeri Diarra's send into dreamland.
The outstanding moment of the opening passages of play was a disappointing one for the match, as Germany's top scorer Marc Stendera was forced off the field, and without him the tournament's most prolific side struggled to find their rhythm. Good pressing from the Malians limited their chances, although the Africans often struggled to make any themselves.
Mali returned after the break looking bright and up for the challenge. Their early pressure looked to have been for nothing though after the referee pointed to the spot for a foul on Jeremy Dudziak. But the Africans held strong as Mukhtar saw his effort saved and, within two minutes, parity was restored.
A foul on the left flank gave Youssouf Kone the chance to swing a cross into the German area and Coulibaly met it perfectly. The defender got free at the front post and his diving header flashed beyond keeper Marvin Schwaebe and into the far corner.
Later, a weak back-pass left Malian hearts in mouths as Hamidou Maiga almost gifted the Germans a path into the last four. Mukhtar should also have atoned for his penalty miss, but directed his header wide, ensuring the game went to extra-time.
Malick Toure should have put Mali ahead for the first time when he headed over from three yards out as the Germans seemed to tire as the additional 30 minutes wore on. A shootout always looked like where it was headed though, and while Adama Traore saw his effort saved, Brandt then fired over before Stark's off-target effort saw Europe's two front-runners go out on spot-kicks in the space of minutes.