The immigration minister, Mark Harper, has resigned for employing an illegal immigrant as a cleaner, Downing Street said on Saturday.

Number 10 said there was "no suggestion that Mr Harper knowingly employed an illegal immigrant" but the prime minister, David Cameron, had "accepted his resignation with regret".

Last year Harper launched a government advertising campaign that targeted racially mixed areas with mobile billboards warning illegal immigrants to "go home or face arrest".

In his resignation letter 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" when he took on the highly sensitive role that the documents provided by the cleaner were genuine.

In 2007 when she was recruited to look after his London flat he was 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 of the need to check the status of employees – he sought fresh evidence.

On Thursday morning, he said, he was informed after checking with immigration officials that she was in the country illegally.

"I immediately notified the home secretary and my permanent secretary. This is now a matter for immigration enforcement," he wrote.

"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." The prime minister said 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," Cameron wrote.

In a limited reshuffle, junior home office minister James Brokenshire has replaced Harper as minister of state, while Karen Bradley moves from the whips office to fill his role.

John Penrose is promoted within the whips office to replace Bradley and Harriet Baldwin is brought into the government ranks as a junior whip.

Home Secretary Theresa May said she was sorry to see Harper go. "Mark has been an excellent minister and he can be proud of the role he has played in sharply reducing immigration to Britain."