UK Immigration Minister Mark Harper has quit after it emerged his cleaner was in the UK illegally.
Downing Street said the Forest of Dean MP offered his resignation after being informed of the highly-embarrassing situation.
But it insisted there was "no suggestion" he "knowingly employed an illegal immigrant".
"The Prime Minister has accepted the resignation of the Immigration Minister, Mark Harper," a spokeswoman said.
"Mark Harper offered his resignation after he was informed that his cleaner did not have indefinite leave to remain in the United Kingdom, despite having shown him documents claiming she did.
"He immediately notified the Prime Minister - who accepted his resignation with regret.
"There is no suggestion that Mr Harper knowingly employed an illegal immigrant."
In his resignation letter Mr Harper said that while he had not broken the law as an employer, he believed that his position meant he must "hold myself to a higher standard than expected of others".
He conceded that he "should have checked more thoroughly" on taking on the highly-sensitive role that the documents the cleaner recruited to look after his London flat provided in 2007 were genuine.
At that point he had been given a copy of her passport and a Home Office letter stating that she had indefinite leave to remain in the UK and the right to work and run a business.
Last month - mindful that he was steering the Immigration Bill through the Commons and publicly warning employers over the need to check the status of employees - he sought fresh evidence.
But on Thursday morning, he said, he was informed after checking with immigration officials that she was in fact in the country illegally.
"I immediately notified the Home Secretary and my Permanent Secretary. This is now a matter for Immigration Enforcement," he said.
"Although I complied with the law at all times, I consider that as Immigration Minister, who is taking legislation through Parliament which will toughen up our immigration laws, I should hold myself to a higher standard than expected of others," he told Mr Cameron.
"I have also considered the impact on my Parliamentary colleagues, the Government and you. I have always believed that politics is a team game, not an individual sport.
"Under the circumstances, I have therefore decided that the right course is for me to return to the backbenches. I am sorry for any embarrassment caused."
Mr Cameron said Mr Harper had "taken an honourable decision" and that he hoped to see him return to the frontbench "before too long".
"I understand your view that, although you carried out checks on your cleaner, you feel that you should hold yourself to an especially high standard as Immigration Minister," Mr Cameron wrote.
"You have taken an honourable decision.
"I have always enormously appreciated your energy and your loyalty. It is typical of you that you should be so mindful of the wider interests of the Government and the Party in reaching the decision that you have, and I am very grateful for that.
"You will be greatly missed, and I hope very much that you will be able to return to service on the frontbench before too long."