A Conservative MP has been forced to resign from the UK government for pushing a plan to safeguard European Union citizens' rights, despite ministers saying they would vote for it.

Alberto Costa tabled an amendment for Wednesday evening's series of Brexit votes that called on Prime Minister Theresa May to strike to safeguard the rights of EU citizens even in the event of a no-deal Brexit.

Home Secretary Sajid Javid said shortly before Costa was forced to resign that the government would support the amendment, but May had indicated the government would oppose it.

If the government does back the plan, it will create an extraordinary situation in which an MP will have been forced to resign for pushing a plan that had the explicit support of Downing Street.

A Downing Street representative said Costa resigned "because he felt strongly" about the issue.

LONDON — A Conservative MP who put forward a plan to safeguard European Union citizens' rights after Brexit has been forced to resign from UK Prime Minister Theresa May's government despite ministers saying Downing Street would back the plan.

Alberto Costa, who resigned as a parliamentary private secretary, had tabled an amendment for Wednesday evening's series of Brexit votes that called on the prime minister to strike a deal with Brussels to safeguard the rights of EU citizens even in the event of a no-deal Brexit.

May had previously indicated that the government would not back the plan, telling MPs that a "separate agreement for citizens' rights is something the EU have been clear they do not have the legal authority for."

Home Secretary Sajid Javid told MPs on Wednesday morning that he had "no problem" with the amendment and that the government would support it. Cabinet Office minister David Lidington later confirmed that the government would support the amendment.

Labour has also indicated it will back the plan, meaning it is likely to pass with a comfortable majority.

If the government does back the plan, it will create an extraordinary situation in which an MP will have been forced to resign for pushing a plan that had the explicit support of Downing Street.

Read more: Theresa May offers MPs a vote to delay Brexit and prevent no-deal

A Downing Street spokesperson said convention dictates that MPs on the government payroll can't table amendments to a government bill regardless of whether the government opposes them.

"There's a long-standing convention that members of the Government payroll don't table amendments to government bills," the spokesperson said.

"Clearly this is an issue that he feels strongly about and so he has chosen to resign from the Government."