For almost six years, Washington secretly shackled JPMorgan Chase & Co., the nation's biggest bank.

Now the chains are off, thanks to bank-friendly regulators in the Trump administration.

In actions never before made public, Obama administration regulators prevented the bank from opening branches in new states as punishment for violating banking rules, according to people familiar with the matter.

JPMorgan's ambitious plan to expand nationally, announced earlier this year, was made possible by the Trump administration's rollback of those restraints, which date from 2012, said the people, who asked not to be identified discussing regulators' impact on the bank's plans.

JPMorgan has racked up more than $30 billion in penalties, legal costs and related obligations since the 2008 financial crisis, some of which stemmed from its acquisitions of Bear Stearns Cos. and Washington Mutual Inc. Missteps include excessive risk taken by the London Whale trader and failing to flag transactions related to Bernard Madoff's Ponzi scheme.

Privately, the U.S. Office of the Comptroller of the Currency stopped JPMorgan from expanding into additional states while resolving compliance breakdowns as part of an unwritten regulatory policy, the people said.

Expansion Ban

While banks often have private conversations with regulators and even gauge their reactions to potential plans, the people with knowledge of the matter described the ban as one of the more extreme ways they exerted their control behind the scenes.

Regulators went to even harsher lengths earlier this year to punish Wells Fargo & Co., placing a cap on its assets after a pattern of lapses and abuses. Janet Yellen, who served as Federal Reserve chair under President Barack Obama, announced the unprecedented punishment on her final workday in office.

JPMorgan, the biggest U.S. bank by assets, operated 5,130 branches in 23 states at the end of last year. With fresh assurances from regulators under President Donald Trump, the people said, it's planning to open 400 branches in as many as 20 new markets in the next five years, including plans to build in Boston, Philadelphia and Washington, D.C.

This is the first time the bank is opening branches in a new state in more than a decade. The moves could translate into an additional $1.5 billion of revenue a year by 2022, according to Morgan Stanley.

'Extremely Excited'

"We are extremely excited to be expanding again, as smart regulatory policy and a competitive corporate tax system help us to deliver on our commitment to invest in our customers and communities," Chief Executive Officer Jamie Dimon said Oct. 12.

JPMorgan has resolved many of its compliance issues, but the OCC still has open enforcement actions against the bank, according to agency data.

Andrew Gray, a JPMorgan spokesman, said the bank wouldn't comment on supervisory issues.

"Opening new branches is a sustainable and long-term investment in the communities we serve," Gray said. "Entering new markets will bring the full force of JPMorgan Chase's business and philanthropic capabilities, create thousands of good-paying jobs, and allow us to serve more customers and local businesses by lending and investing in their community."

OCC spokesman Bryan Hubbard declined to comment.

New Branches

In loosening their grip on JPMorgan, authorities removed a critical barrier to the lender's growth. A 1994 law prohibits mergers between banks if the transaction would give any of them control of more than 10 percent of U.S. deposits.

With $1.3 trillion, JPMorgan already controls more than 10 percent — second only to Bank of America Corp. — which means adding branches in new markets is one of its only avenues for expansion.

The reversal comes amid anti-regulatory fervor under Trump. It's also consistent with the declared willingness of the new OCC head, Joseph Otting, to give financial institutions more flexibility when resolving concerns raised by OCC staff.

Otting worked closely with future Treasury Secretary Steven Mnuchin at OneWest Bank, now part of CIT Group Inc., when the lender came under fire for its mortgage-servicing business.

The OCC has overturned measures put in place by Thomas Curry, who led the agency from 2012 to 2017. He instituted tough standards in an effort to change the perception that regulators were too close to the institutions they were meant to police.

Relaxed Stance

Banks are responding to friendlier regulators under Trump by pushing into new markets and reassessing deals that likely would've been vetoed under Obama. Many elected officials and policymakers blamed reduced oversight for the 2008 financial crisis, which triggered the longest and deepest recession since the 1930s.

One person familiar with JPMorgan's plans said regulation was only partly to blame for JPMorgan not broadening its consumer bank in the decade after the crisis. The bank constantly evaluated ways to expand the consumer bank, but executives were hesitant due to the cost and difficulty, the person said.

JPMorgan is embarking on the biggest expansion of its consumer bank in a decade as new liquidity rules encourage banks to draw more funding from deposits, which tend to be cheaper, and rising interest rates stiffen the competition for retail customers. Bank of America also announced plans to open up branches in new markets earlier this year.

"I've been waiting to do this for 10 years," Dimon said in September.