A US law firm has lost two high-profile clients over its refusal to defend the anti-gay Defense of Marriage Act.

King & Spalding was seemingly lobbied by gay rights campaigners not to defend the law but has now lost the National Rifle Association and Virginia Attorney General Ken Cuccinelli as clients.

After the Obama administration announced earlier this year that it would not defend the law against legal challenges, the Republican-controlled House said it would continue to do so.

The House hired King & Spalding last month and reports said the firm would earn $520 an hour – up to a cap of $500,000.

Then, chairman Robert D Hays said the firm had made a mistake in accepting the brief.

He told reporters that the mistake was his and added: “In reviewing this assignment further, I determined that the process used for vetting this engagement was inadequate.”

Partner Paul Clement, a former US Solicitor General, then resigned from the firm in protest, saying that lawyers should always complete representations.

Resigning, he wrote that regardless of his own views on the law, “a representation should not be abandoned because a client’s legal position is extremely unpopular in certain quarters”.

Mr Clement is to continue representing the House.

Last week, Mr Cuccinelli said the firm was guilty of an “obsequious act of weakness” in bowing to pressure from the gay rights lobby.

Yesterday, the National Rifle Association followed suit.

NRA general counsel David Lehman wrote to the firm: “We believe King & Spalding’s decision is indefensible and raises serious concerns about its ability to be a reliable and effective advocate for any client facing potentially controversial litigation.”

King & Spaulding has not commented on the client losses.

The firm has scored well in the Human Rights Campaign Corporate Equality Index for the last four years and says it is committed to equality and “actively recruits LGBT law students”.