CashCall Inc., an internet lender accused of hiding behind an American Indian tribe to break state laws, agreed to pay nearly $12 million to settle charges filed by Minnesota’s attorney general.

The company, based in California, was also barred from further business in the state, Attorney General Lori Swanson said Thursday.

“The company engaged in an elaborate scheme to collect payments far higher than allowed by state law,” Swanson said in announcing the settlement. CashCall must cancel all outstanding loans, pay back consumers and “undo any adverse reporting to the credit bureaus.”

CashCall’s founder and owner, J. Paul Reddam, and its attorney didn’t return calls seeking comment. The firm has made similar settlements in other states.

The settlement is among the largest involving the controversial payday credit industry in Minnesota. The state’s leverage was strengthened by a 2015 Minnesota Supreme Court decision that held that out-of-state lenders have to follow Minnesota’s law for online loans.

In the settlement approved by Hennepin County District Judge Karen Janisch, CashCall Inc. must pay $4.5 million in restitution to consumers and cancel more than $5.2 million in outstanding balances on more than 2,200 loans. It must notify third parties that bought outstanding loan balances totaling more than $1.9 million that the debts on more than 1,100 loans would be forgiven.

Swanson sued CashCall in 2013, accusing the company and its subsidiaries of engaging in an “elaborate ruse” to deceive borrowers and regulators and fleece them with illegally high rates on internet loans.

That suit alleged CashCall fraudulently claimed its loans were subject to tribal sovereign immunity because they were made by a South Dakota company called Western Sky Financial Inc., which is owned by an Indian tribe member. However, tribal sovereign immunity doesn’t protect an individual member.

The loans were quickly sold to CashCall and its subsidiaries.

The companies, which had been running ads on radio and TV in Minnesota, made loans from $850 to $10,000 and charged annual percentage rates of up to 342 percent, according to the lawsuit. In Minnesota, a licensed lender making a similar loan could charge an APR of about 22 percent.

The “rent-a-tribe” arrangement emerged as increased regulations squeezed the business of providing expensive consumer loans over the internet and lenders sought new ways to ply their wares.

Some online payday lenders had tried to evade state lending and consumer protection laws by claiming that the loans are only subject to the laws of their home state or country. In 2013, the internet payday loan industry had estimated loan volume of $15.9 billion.

The ostensible benefit of payday loans is that they allow borrowers to pay their basic living expenses in advance of their next paycheck. However, many borrowers rely on the loans as their main source of long-term credit and don’t repay them on time, incurring extra charges. State law requires payday lenders to be licensed with the Minnesota Department of Commerce.

Mike Rothman, commissioner of the Minnesota Department of Commerce, said the agency, which failed to win legislative approvals for tougher lending standards two years ago, would return to the 2017 Minnesota Legislature to request a cap of payday interest rates at 36 percent. The agency also wants to limit the number of loans to prevent borrowers from the “debt trap” of interest and penalties.

Meanwhile, Sunrise Community Banks of St. Paul has won awards and consumer-group laurels for an alternative product that provides emergency, unsecured loans through employers that must be paid back within one year at a maximum effective rate of 25 percent. It also limits the size and number of loans. Sunrise developed its program with Lutheran Social Service, a major provider of financial counseling to consumers who get in trouble through payday loans.