A judge has approved an agreement for US president Donald Trump to pay 25 million dollars (£20 million) to settle lawsuits over his now-defunct Trump University.
The decision by district judge Gonzalo Curiel in San Diego ends nearly seven years of legal battles with customers who claimed they were misled by failed promises to teach success in real estate.
The ruling settles two class-action lawsuits and a civil lawsuit by New York attorney general Eric Schneiderman.
Mr Trump had vowed never to settle, but said after he was elected that he did not have time for a trial, even though he believed he would have prevailed.
Under the terms of the settlement, he admits no wrongdoing.
Attorneys for the customers said thousands will get at least 90% of their money back.
The White House did not immediately respond to a request for comment on the ruling.
The lawsuits alleged that Trump University gave nationwide seminars that were like infomercials, constantly pressuring people to spend more and, in the end, failing to deliver.
Roughly 3,730 claims were submitted.
Trump University dogged the Republican businessman throughout the campaign as rivals used his depositions and extensive documents filed in the lawsuits to portray him as dishonest and deceitful.
Mr Trump brought more attention on the matter by repeatedly assailing Judge Curiel, insinuating that the Indiana-born judge's Mexican heritage exposed a bias.
The judge rejected requests by two former students who objected to the settlement, scuttling the possibility of derailing the agreement with the prospect of more litigation.
Sherri Simpson, a Fort Lauderdale, Florida, attorney, said she and a partner paid 35,000 dollars in 2010 to enrol in Trump University's "Gold Elite" programme, to be paired with a mentor who would teach them Mr Trump's secret real estate investment strategies.
Ms Simpson, who appeared in two anti-Trump campaign ads, said they got little for their money - the videos were five years old, the materials covered information that could be found free on the internet and her mentor did not return calls or emails.
Ms Simpson argued that she should have been given more opportunity to opt out of the settlement.
A ttorneys for Mr Trump and those suing him say the deadline to opt out was in November 2015, and that she missed her chance.
Another customer, Harold Doe, objected because he wanted more money.
In clearing those final hurdles, the president brought closure to the trio of lawsuits, the first of which was filed in April 2010.
When attorneys reached a deal shortly after Mr Trump's election, Judge Curiel said he hoped it would be part of "a healing process that this country very sorely needs".
A month later, he granted preliminary approval of the deal.
The settlement was announced 10 days before a trial was set to begin, sparing Mr Trump what would have been a major distraction.
The trial would have been pinned on whether a jury believed Mr Trump misled customers by calling the business a university when it was not an accredited school, and by falsely advertising that he hand-picked instructors.
Court documents unsealed last year revealed strategies for enticing people to enrol even if they could not afford it.
The documents outlined how employees should guide people through "the rollercoaster of emotions" after they express interest and tells employees to be "very aggressive during these conversations to in order to push them out of their comfort zones".
Transcripts of about 10 hours of Mr Trump's depositions provided additional material to rivals, though Judge Curiel denied a request to release video of Mr Trump's testimony that would have likely been used in campaign attack ads.
Mr Trump acknowledged in the depositions that he played on people's fantasies, and he could not recall names of his employees despite his advertising pitch that he hand-picked them.
Mr Trump has repeatedly claimed a 98% customer satisfaction rate on internal surveys.
Plaintiffs countered that students were asked to rate the product when they believed they still had more instruction to come and were reluctant to openly criticise their teachers on surveys which were not anonymous.