West Ham were staring at a defeat to bottom-of-the-table Huddersfield before Manuel Pellegrini's substitutes changed the game.
Manuel Pellegrini praised Javier Hernandez's persistence after his late brace secured a dramatic 4-3 win for West Ham over Huddersfield Town.
Mark Noble gave the Hammers a 15th-minute lead from the penalty spot but Juninho Bacuna hit back swiftly and a Karlan Grant double meant the Premier League's bottom side were 3-1 up with 15 minutes to play.
But Angelo Ogbonna reduced the arrears before former Manchester United and Real Madrid striker Hernandez sent the London Stadium into raptures.
"Javier was playing well recently but he had a little pressure of not scoring," Pellegrini told reporters.
"So, it was good for him to come from the bench and he played very well and decided the game with two goals."
Similar praise was reserved for fellow substitutes Samir Nasri and Lucas Perez.
"I also think Samir Nasri changed the game of our team and Lucas Perez was always dangerous in the box, so the three substitutes did very well and that's the reason why you need a good squad and not just a team," Pellegrini added, before acknowledging the first half was not up to standard.
"The complete team did not play well in the first 45 minutes. We didn't play with the pace that we need, we didn't do the movements we needed to do, and the playmakers that had to put in good balls for the attackers didn't."
Disappointment was palpable for Huddersfield boss Jan Siewert, who saw his relegation-doomed side carry out his strategy to perfection for the most part.
"We've worked on today's game plan to beat West Ham and you could see it at 3-1 up, " he told reporters, with Town marooned at the foot of the table, 16 points from safety.
"To then lose the game after three substitutions is hard to describe. I'm truly disappointed. There are reasons why we are the bottom of the table."