Super Eagles forward, Kelechi Iheanacho scored on his second start of the season to ensure Leicester City returned to winning ways.
In a much-changed side, Brendan Rodgers hoped to return to winning ways after suffering consecutive losses against Manchester City and league leaders, Liverpool.
The foxes started on a bright note with West Ham conceding a penalty, however, it was missed by winger, Gray.
Minutes later, the Nigerian forward who was starting in place of talisman, Jamie Vardy stepped up to score the opening goal.
West Ham equalized on the stroke of half time before Gray made up for his mistake by scoring the winning goal in the 56th minute of the game.
The victory extends the gap between Leicester and third-placed Manchester City to four points.