The 38-year-old won a specially-arranged race to give him a final chance to qualify at the British Championships, but his time of 27 minutes 47 seconds was nearly 20 seconds off the time required to qualify.
Farah won the 5,000m-10,000m double at the London Olympics in 2012 and repeated the feat four years later in Rio de Janeiro.
He then turned his attention to the marathon, but after mixed results returned to the track in the hope of one final shot at Olympic glory.
“I’ve been lucky enough to have had the long career I’ve had. I’m very grateful but that’s all I had today,” said Farah, who refused to confirm if he had just run his final track race.
“It’s a tough one. I always said if I can’t compete with the best I’m not just going to go there to finish in a final. Tonight it shows it’s not good enough.”
Not to be for @Mo_Farah tonight but this man is and always will be a champion 🥇🥇🥇🥇 https://t.co/CK3BnTSB9t
— Team GB (@TeamGB) 1624656734000
Farah was blighted by an ankle problem when he finished eighth at the British 10,000m Championships on June 5 in a time of 27:50.64.
Despite having the help of pacemakers in Manchester, his time improved by only three seconds to remain well off the pace needed to qualify.
After his Belgian training partner Bashir Abdi peeled off the front with nine laps to go, Farah steadily started falling behind the required time and he wore a pained expression as he came down the final straight on the last lap.
That contrasted sharply to the kick Farah had in his glory years to become an Olympic great.
He famously capped “Super Saturday” on the track for Team GB at the home games in 2012 as Jessica Ennis-Hill claimed heptathlon gold and Greg Rutherford won the long jump in the space of 44 minutes.
Farah also won six world championship gold medals and two silvers.
However, his success has been dogged by his links to banned American coach Alberto Salazar.
Farah was coached by Salazar at the Nike Oregon Project from 2011 to 2017.
Salazar is serving a four-year ban for breaking anti-doping rules following a probe by the US Anti-Doping Agency (USADA).
Farah has never tested positive for any banned substance, but admitted last year to have suffered “financially and emotionally” from the backlash to his association with Salazar.
Born in Somalia, Farah arrived in England at the age of eight and was knighted in 2017 for his services to athletics.