Sergeant Jeremy Scott said he hoped the former prime minister's death at the age of 87 was 'painful and degrading'.
The 52-year-old Metropolitan Police officer also suggested the world would be a 'better place' if David Cameron, too, were dead.
Scotland Yard said today: 'The officer concerned, today submitted his resignation and it was accepted with immediate effect.'
However a spokesman said he would be 'receiving his full pension at an appropriate time' but refused to give further details of the amount involved.
Met Commander Allan Gibson added: 'This officer's behaviour was completely unacceptable and it is right that he has resigned.'
Meanwhile today another public figure, a Labour Party official, was also in hot water for saying Tony Blair should be buried in the same coffin as Mrs Thatcher.
Writing on Twitter, Sgt Scott questioned whether a flypast would 'bomb' Lady Thatcher's coffin and said her passing was '87 years too late'.
He said: 'Goodnight Twitter. The world is a better place today now that c*** is dead. Now for Cameron, May and Osborne.'
The comments of the police officer, sworn to uphold the law, mark a new low in the bitter hate campaign ahead of Lady Thatcher's funeral.