Arsenal's Germany contingent are on a World Cup collision course with their French clubmates.
Lukas Podolski, nursing an injury, watched from the sidelines but he will hope to be fit to face France duo Laurent Koscielny and Olivier Giroud in Friday's quarter-final after Les Bleus saw off Nigeria.
Germany were firm favourites to beat Algeria but they were forced onto the back foot in the first half with Mertesacker at full stretch to help keep the African side at bay.
Ozil showed glimpses of his quality and forced an early save from Rais M'Bolhi. The Arsenal playmaker also went close in extra-time but was stopped by Rafik Halliche as he surged into the penalty area.
By then Germany were ahead, thanks to an improvised finish from Andre Schurrle, who diverted Thomas Muller's low cross past M'Bolhi with his heel.
Ozil rammed in a rebound with two minutes left to double Germany's advantage before Abdelmoumene Djabou scored a late consolation for an impressive Algeria side.Copyright 2015 The Arsenal Football Club plc. Permission to use quotations from this article is granted subject to appropriate credit being given to www.arsenal.com as the source 30 Jun 2014