Martin Shrkeli, the smirking "Pharma Bro" vilified for jacking up the price of a lifesaving drug, was sentenced Friday to seven years in prison for defrauding investors in two failed hedge funds.

The self-promoting pharmaceutical executive notorious for trolling critics online was convicted in a securities fraud case last year unconnected to the price increase dispute.

Shkreli, his cocky persona nowhere to be found, cried as he told U.S. District Judge Kiyo Matsumoto he made many mistakes and apologized to investors.

"I want the people who came here today to support me to understand one thing, the only person to blame for me being here today is me," he said. "I took down Martin Shkreli."

He said that he hopes to make amends and learn from his mistakes and apologized to his investors.

MARTIN SHKRELI CONTROVERSIES: A TIMELINE OF EVENTS

"I am terribly sorry I lost your trust," he said. "You deserve far better."

Prosecutors argued that the 34-year-old was a master manipulator who conned wealthy investors and deserved 15 years in prison. His lawyers said he was a misunderstood eccentric who used unconventional means to make those same investors even wealthier, and deserved 18 months or less in prison.

The judge insisted that the punishment was not about Shkreli's online antics or raising the cost of the drug.

"This case is not about Mr. Shkreli's self-cultivated public persona ... nor his controversial statements about politics or culture," the judge said, calling his crimes serious.

He was also fined $75,000 and received credit for the roughly six months he has been in prison.

The judge ruled earlier this week that Shkreli would have to forfeit more than $7.3 million in a brokerage account and personal assets including his one-of-a-kind Wu-Tang Clan album that he boasted he bought for $2 million. The judge said the property would not be seized until Shkreli had a chance to appeal.

Attorney Benjamin Brafman told Matsumoto Friday that he sometimes wants to hug Shkreli and sometimes wants to punch him in the face, but he said his outspokenness shouldn't be held against him.

‘PHARMA BRO’ MARTIN SHKRELI’S EX-LAWYER FOUND GUILTY OF HELPING HIM COVER UP FINANCIAL FRAUD

Assistant U.S. Attorney Jacquelyn Kasulis said Shkreli deserved the stiffer sentence not because he is "the most hated man in America," but because he is a criminal convicted of serious fraud. She said the judge had to consider his history and said he has "no respect whatsoever" for the law, or the court proceedings.

"I also want to make clear that Mr. Shkreli is not a child," Kasulis said. "He's not a teenager who just needs some mentoring. He is a man who needs to take responsibility for his actions."

Unapologetic from the beginning, when he was roundly publicly criticized for defending the 5,000 percent price increase of Daraprim, a previously cheap drug used to treat HIV, Shkreli seemed to drift through his criminal case as if it was one big joke.

After his arrest in December 2015, he taunted prosecutors, got kicked off of Twitter for harassing a female journalist, heckled Clinton from the sidewalk outside her daughter's home, gave speeches with the conservative provocateur Milo Yiannopoulos and spent countless hours livestreaming himself in his apartment.

He was tight-lipped when faced with a barrage of questions about the price hike from members of Congress a couple of months later, citing his Fifth Amendment right not to incriminate himself. After the hearing, he tweeted that the lawmakers were "imbeciles."

Shkreli insisted he was being persecuted by prosecutors for being outspoken and confidently predicted after his conviction that he was unlikely to be sentenced to jail.

Things abruptly changed, though, last fall after he jokingly offered his online followers a $5,000 bounty to anyone who could get a lock of Hillary Clinton's hair. The judge revoked his bail and threw him in jail, a decision that she defended Friday.

That didn't tame Shkreli completely. He corresponded with journalists, ridiculing the personal appearance of one female reporter who asked him for an interview.

Before sentencing him, the judge said that it was up to Congress to fix the issue of the HIV price-hike. And she spoke about how his family and friends "state, almost universally, that he is kind and misunderstood" and willing to help others in need.

She said it was clear he is a "tremendously gifted individual who has the capacity for kindness."

She quoted from letters talking about generous acts like counseling a rape victim, teaching inmates math and chess, and funding family members.

The defense had asked the judge to consider the letters in its case for leniency, including professionals he worked with who vouched for his credentials as a self-made contributor to pharmaceutical advances.

Other testimonials were as quirky as the defendant himself. One woman described how she became an avid follower of Shkreli's social media commentary about science, the pharmaceutical industry, but mostly, about himself. She suggested that those who were annoyed by it were missing the point.

"I really appreciate the social media output, which I see on par with some form of performance art," she wrote.

Another supporter said Shkreli's soft side was demonstrated when he adopted a cat from a shelter — named Trashy — that became a fixture on his livestreams. Another letter was from a man who said he met Shkreli while driving a cab and expressed his appreciation at how he ended up giving him an internship at one of his drug companies.

In court filings, prosecutors argued that Shkreli's remorse about misleading his investors was not to be believed.

"At its core, this case is about Shkreli's deception of people who trusted him," they wrote.