Peterborough’s co-owners reluctantly accepted his resignation following a run of one win in 17 Championship matches.
Ferguson’s last match in charge of Posh was Saturday’s 1-0 defeat at Derby County which left them 23rd in the table and five points from safety.
Ferguson, 50, returned to Peterborough for a second time in January 2019 almost eight months after resigning as manager of Doncaster Rovers.
A Posh statement said: ‘Peterborough United can confirm that the co-owners have accepted the resignation of manager Darren Ferguson following a phone call made by Darren to Darragh MacAnthony on Sunday.
Ferguson steered Posh to automatic promotion from League One last term and has four promotions on his CV during his time at the Weston Homes Stadium.
Co-owner Darragh MacAnthony said: “Myself and my two partners regard Darren as one of the greatest managers of this football club, most certainly in the modern era. The success we have enjoyed with him at the helm has been unrivalled and he will always be described as a legend by myself and my partners.
“I want to personally thank him for all his hard work on behalf of the club, particularly in his third spell when he dealt with the unquestionable frustration at the season being cut-short due to Covid-19 and then responding by securing promotion the following season against all the odds.
“The financial constraints he had to work under due to the impact of no supporters inside the stadium was something that nobody could have foreseen, and he dealt with that in such an admirable and methodical way. He created a working environment that the players enjoyed despite the restrictions and he deserves enormous credit for that and the success we enjoyed. We all wish the Gaffer and his wonderful family nothing but the best for the future.”
Ferguson could not prevent Rovers spiralling out of League One after taking over from Paul Dickov in October 2015 but then guided the club to promotion from League Two at the first attempt. He resigned in June 2018 after Rovers finished 15th in League One.