For many rioters who stormed the U.S. Capitol on Jan. 6, self-incriminating messages, photos and videos that they broadcast on social media before, during and after the insurrection are influencing even their criminal sentences.

Earlier this month, U.S. District Judge Amy Jackson read aloud some of Russell Peterson’s posts about the riot before she sentenced the Pennsylvania man to 30 days imprisonment. “Overall I had fun lol,” Peterson posted on Facebook.

The judge told Peterson that his posts made it “extraordinarily difficult” for her to show him leniency.

“The ’lol’ particularly stuck in my craw because, as I hope you’ve come to understand, nothing about January 6th was funny,” Jackson added. “No one locked in a room, cowering under a table for hours, was laughing.”

Among the biggest takeaways so far from the Justice Department’s prosecution of the insurrection is how large a role social media has played, with much of the most damning evidence coming from rioters’ own words and videos.

FBI agents have identified scores of rioters from public posts and records subpoenaed from social media platforms. Prosecutors use the posts to build cases. Judge now are citing defendants’ words and images as factors weighing in favor of tougher sentences.

As of Friday, more than 50 people have been sentenced for federal crimes related to the insurrection. In at least 28 of those cases, prosecutors factored a defendant’s social media posts into their requests for stricter sentences, according to an Associated Press review of court records.

Many rioters used social media to celebrate the violence or spew hateful rhetoric. Others used it to spread misinformation, promote baseless conspiracy theories or play down their actions. Prosecutors also have accused a few defendants of trying to destroy evidence by deleting posts.

Approximately 700 people have been charged with federal crimes related to the riot. About 150 of them have pleaded guilty. More than 20 defendants have been sentenced to jail or prison terms or to time already served behind bars. Over a dozen others received home confinement sentences.

Rioters’ statements, in person or on social media, aren’t the only consideration for prosecutors or judges. Justice Department sentencing memos say defendants also should be judged by whether they engaged in any violence or damaged property, whether they destroyed evidence, how long they spent inside the Capitol, where they went inside the building and whether they have shown sincere remorse.

Prosecutors recommended probation for Indiana hair salon owner Dona Sue Bissey, but Judge Tanya Chutkan sentenced her to two weeks in jail for her participation in the riot. The judge noted that Bisssey posted a screenshot of a Twitter post that read, “This is the First time the U.S. Capitol had been breached since it was attacked by the British in 1814.”

“When Ms. Bissey got home, she was not struck with remorse or regret for what she had done,” Chutkan said. “She is celebrating and bragging about her participation in what amounted to an attempted overthrow of the government.”

FBI agents obtained a search warrant for Andrew Ryan Bennett’s Facebook account after getting a tip that the Maryland man live-streamed video from inside the Capitol. Two days before the riot, Bennett posted a Facebook message that said, “You better be ready chaos is coming and I will be in DC on 1/6/2021 fighting for my freedom!.”

Judge James Boasberg singled out that post as an “aggravating” factor weighing in favor of house arrest instead of a fully probationary sentence.

“The cornerstone of our democratic republic is the peaceful transfer of power after elections,” the judge told Bennett. “What you and others did on January 6th was nothing less than an attempt to undermine that system of government.”

Senior Judge Reggie Walton noted that Lori Ann Vinson publicly expressed pride in her actions at the Capitol during television news interviews and on Facebook.

“I understand that sometimes emotions get in the way and people do and say stupid things, because it was ridiculous what was said. But does that justify me giving a prison sentence or a jail sentence? That’s a hard question for me to ask,” Walton said.

Prosecutors asked for a one-month jail sentence for Vinson, but the judge sentenced the Kentucky nurse to five years of probation and ordered her to pay a $5,000 fine and perform 120 hours of community service.

In the case of Felipe Marquez, the judge found social media posts belied serious mental health issues that needed treatment rather than incarceration. Marquez recorded cellphone videos of himself with other rioters inside the office of Sen. Jeff Merkley, D-Ore. Back at home in Florida, Marquez posted a YouTube video in which he rapped about his riot experience to the tune of Shaggy’s “It Wasn’t Me.” with lyrics that included, “We even fist-bumped police,” and “We were taking selfies.”

In the video, Marquez wore a T-shirt that said, “Property of FBI.”

Prosecutors had recommended a four-month jail sentence, but U.S. District Judge Rudolph Contreras sentenced him instead to three months of home confinement with mental-health treatment, followed by probation. “I do think you have some serious issues you need to address. That played a large role in my sentencing decision,” he said.

Judge Jackson gave Andrew Wrigley a history lesson before she sentenced the Pennsylvania man to 18 months of probation. Wrigley posted a photo on social media of him holding a 1776 flag during the riot. The judge said the gesture didn’t honor the nation’s founders.

“The point of 1776 was to let the people decide who would rule them. But the point of the attack on the Capitol was to stop that from happening,” Jackson said. “The point of the attack on the Capitol was to subvert democracy, to substitute the will of the people with the will of the mob.”

Videos captured New Jersey gym owner Scott Fairlamb punching a police officer outside the Capitol. His Facebook and Instagram posts showed he was prepared to commit violence in Washington, D.C., and had no remorse for his actions, prosecutors said.

Senior Judge Royce Lamberth said other rioters in Fairlamb’s position would be “well advised” to join him in pleading guilty.

“You couldn’t have beat this if you went to trial on the evidence that I saw,” Lamberth said before sentencing Fairlamb to 41 months in prison.

But it worked to the advantage of one. Virginia charter boat captain Jacob Hiles likely avoided a stricter sentence by posting videos and photos of him and his cousin at the Capitol. A day after the riot, Hiles received a private Facebook message from a Capitol police officer who said he agreed with Hiles’ “political stance” and encouraged him to delete his incriminating posts, according to prosecutors.

The officer, Michael Angelo Riley, deleted his communications with Hiles, but investigators recovered the messages from Hiles’ Facebook account, prosecutors said. Riley was indicted in October on obstruction charges.

On Monday, Jackson sentenced Hiles to two years of probation. Prosecutors said the case against Riley may have been impossible without Hiles’ cooperation.