Tottenham reached the Champions League last 16 after roaring back from two goals behind to beat Olympiacos 4-2.
After Jose Mourinho saw his side start superbly in the first half against West Ham, they began awfully and were lucky, as half time approached, to be just two down through a fantastic 25-yard strike from Youseff El Arabi and a close-range effort from Ruben Semedo.
Just before the half ended they got the luck they needed, as Yassine Meriah took an air shot at an attempted clearance and allowed Dele Alli to make the deficit manageable.
In the second half Spurs were a different side and Harry Kane got them level when he slotted home Lucas Moura's pull-back before Serge Aurier put them in front with a superb half-volley following silky footwork from Alli and a, perhaps inadvertent, flick from Son Heung-Min.
Kane then nodded his second from Christian Eriksen's superb inswinging free-kick to become the quickest player to 20 goals in the Champions League.
The win puts Tottenham on 10 points from five games and secures their progression from the group stages, although Bayern Munich are already confirmed Group B winners.