According to the BBC, with France scoring twice in the last 11 minutes of the match played in Brasilia on Monday to reach the quarter-finals, 52-year-old Keshi, who was appointed coach in 2011, decided to take full responsibility for the loss and quit.
Nigeria captain Joseph Yobo also retired from international football following the team's exit.
Fenerbahce's Yobo, 33, scored a late own goal after Paul Pogba's header had broken Nigerian resistance.
Keshi had offered to resign after last year's Africa Cup Of Nations triumph, citing a lack of support and respect, although he was persuaded to stay on by Nigeria's sport minister.
A group stage win against Bosnia-Hercegovina helped Nigeria reach the knockout stages of the World Cup for the first time since 1998, despite the players being involved in a row over bonuses.
Keshi becomes the sixth manager to leave his job during the World Cup, following the departures of Honduras's Luis Suarez, Iran's Carlos Queiroz, Japan's Alberto Zaccheroni, Italy's Cesare Prandelli and Ivory Coast's Sabri Lamouchi.
Keshi, who captained Nigeria at the 1994 World Cup finals, was previously in charge of Mali and Togo.