Judge Beryl A. Howell accepted a motion by the Justice Department filed last May to dismiss the lawsuit, which argued that the group founded in 2010 to advocate for tough Wall Street reforms lacked standing to sue.

"The plaintiff has failed to meet its burden to show

it has suffered an injury in fact," Howell wrote in her opinion, filed on Wednesday in the District Court for the District of Columbia.

Better Markets sued the Justice Department last February, contending that the then-record settlement reached in November 2013 was "unlawful" and gave JPMorgan Chase & Co "blanket civil immunity" for its conduct without sufficient judicial review.

The Justice Department reached a wide-ranging deal with the largest U.S. bank that included a $2 billion civil penalty and a $4 billion consumer relief package.

Better Markets was seeking to have the court prevent the Justice Department from enforcing the settlement until a judge reviewed it.

Better Markets Chief Executive Officer Dennis Kelleher said in a statement that the law allowing settlements remained deficient, not the advocacy group's lawsuit.

"Such backroom deals should not be allowed in a democracy worthy of its name. We will be carefully evaluating the court's opinion before determining our next steps," Kelleher said.

JP Morgan Chase & Co declined comment.

In a statement, the Justice Department welcomed the decision and reiterated that it remains "serious about examining the root causes of the financial crisis, and holding the appropriate people and companies accountable."

(Reporting by Lindsay Dunsmuir; Editing by Tom Brown and David Gregorio)

By Lindsay Dunsmuir