The 34-year-old, whose winning run in the 5,000m at Olympics and world finals stretched back to 2011, fought desperately to claw back the deficit in the finishing straight but Edris held on to win in 13min 32.79sec.
Andy Butchart then raced to the front alongside Farah briefly on the penultimate lap, as Yomif Kejelcha and Edris took over at the bell.
Farah had romped to victory in the longer event on the opening night of the championships last weekend.
"I gave it all but I had nothing left at the end", a crestfallen and emotional Farah said.
"I don't think there was any more I could have done". Tactically, I was trying to cover every move.
Quite simply, Farah will go down in history as Britain's best-ever athlete and one of the greatest the world has ever witnessed.
Regulator warns MPs on Brexit transition risks
Woods wrote that financial services are in danger of becoming dislocated and fragmented after Brexit. It has warned it may need to ask for more if the biggest risks around Brexit crystallise.
Farah, a two-time double world champion and two-time double Olympic champion, finished in 13:33.22.
So they caught him in the end, Mo Farah losing his last race on the track inside a packed London Olympic Stadium, beaten into second place after a savagely competitive 5,000 metres final. The better man won.
Paul Chelimo of the United States took bronze.
As the group went through the 3,000m mark Australian Patrick Tiernan was the one who made a decision to change the pace and he opened up a little gap between Chelimo, Farah and the rest of the pack.
Roared on again by a home crowd, the Briton had looked comfortable from the start.
Pearson delivered the flawless championship performance too, her 12.59 seconds run from the front and enough to hold off the American Dawn Harper Nelson, with Germany's Pamela Dutkiewicz beating world record holder Kendra Harrison for the bronze.
- Reports say Barcelona could turn their attention to Real Madrid's Marco Asensio
- Omarosa appearance at black journalist conference doesn't go well
- Redskins linebacker Trent Murphy out for the season with torn ACL
- Canada's Denis Shapovalov takes down Rafael Nadal at Rogers Cup
- Millions of Ransom Demanded by Hackers for Stolen HBO Data
- Updates from Premier League opener at Selhurst Park
- Brooks Criticizes Strange in Alabama Senate Campaign Ad
- Pahlaj Nihalani removed as CBFC chief; Prasoon Joshi appointed new chairperson
- How to view the solar eclipse
- Clarets draw old rivals in League Cup