Matt Hancock has quit as health secretary the day after video footage emerged of him kissing an aide in his ministerial office in a breach of coronavirus restrictions.

Images and video showed Mr Hancock in an embrace with aide Gina Coladangelo last month, and he was facing increasing pressure to quit over the breaking of social-distancing rules.

Mr Hancock - the west Suffolk MP - wrote to prime minister Boris Johnson on Saturday and said: "The last thing I would want is for my private life to distract attention from the single-minded focus that is leading up out of this crisis."

He said: "We owe it to people who have sacrificed so much in this pandemic to be honest when we have let them down as I have done by breaching the guidance."

Former Chancellor and Home Secretary Sajid Javid will replace Mr Hancock in the health job, Downing Street has announced.

In a video posted on Twitter, Matt Hancock said: "I understand the enormous sacrifices that everybody in this country has made, you have made. And those of us who make these rules have got to stick by them and that's why I've got to resign.

"I want to thank people for their incredible sacrifices and what they've done. Everybody working in the NHS, across social care, everyone involved in the vaccine programme and frankly everybody in this country who has risen to the challenges that we've seen over this past 18 months."

In response, the prime minister wrote: "You should leave office very proud of what you have achieved - not just in tackling the pandemic, but even before Covid-19 struck us."

Mr Johnson had refused to sack Mr Hancock, with his spokesman saying the PM considered the matter closed after receiving his apology on Friday.

Mid Norfolk MP George Freeman tweeted: "Respect to @MattHancock for making the right decision. For lots of reasons: not least that he & his family can now be allowed some privacy to tackle their personal crisis. He stepped up in the eye of the storm & Westminster politics takes a huge toll on partners & marriages."

North Norfolk MP Duncan Baker had called for Mr Hancock to resign, becoming the first Conservative MP in the country to do so openly.

In a statement to this newspaper before Mr Hancock resigned, Mr Baker said: “In my view people in high public office and great positions of responsibility, should act with the appropriate morals and ethics that come with that role. Matt Hancock, on a number of measures has fallen short of that.

“As an MP who is a devoted family man, married for twelve years with a wonderful wife and children, standards and integrity matter to me. I will not in any shape condone this behaviour, and I have in the strongest possible terms told the government what I think.”

Asked whether Mr Hancock should therefore resign, Mr Baker responded: “Yes", following up with "and I have said that to the government."

Labour leader Sir Keir Starmer tweeted: "Matt Hancock is right to resign. But Boris Johnson should have sacked him."

Jonathan Ashworth, Labour's shadow health secretary, said: "It is right that Matt Hancock has resigned. But why didn't Boris Johnson have the guts to sack him and why did he say the matter was closed?

"Boris Johnson has demonstrated that he has none of the leadership qualities required of a Prime Minister.

"Hancock's replacement cannot carry on business as usual. On Hancock's watch waiting times soared, care homes were left exposed to Covid and NHS staff were badly let down. Our NHS deserves much better."

Following his resignation, Ed Davey, leader of the Liberal Democrats, tweeted: "Matt Hancock told millions of people that they couldn’t hug their loved ones, and now refuses to resign even though he broke his own guidelines. The fact the Prime Minister has failed to take action shows the utter contempt this government has for the British people."