As former President Donald Trump heads to court Thursday for an initial appearance on federal charges connected to his effort to overturn his loss in the 2020 election, his allies in Congress and elsewhere have decried the prosecution for targeting his freedom of speech.

But legal experts and the indictment itself said that while Trump has a right to lie about the results of the 2020 election, steps beyond just statements, such as orchestrating sets of false electors, move beyond the protections of the First Amendment.

“President Trump could say every day that he won the election, that the election was stolen, and that’s not a crime,” said Jimmy Gurulé, a criminal law professor at Notre Dame Law School and former official at the Justice and Treasury departments.

“Then when he takes action to prevent the peaceful transfer of power, based on this belief that he’s expressed, that is the action that converts his protected speech into criminal conduct that can be punished,” Gurulé said.

(Related: Learn the political positions, bias ratings and factual levels for all the prominent 2024 candidates.)

The indictment, which charges Trump with conspiracy, obstructing an official proceeding, fraud against the United States and a conspiracy to deprive people of the right to vote, focuses on steps the former president took beyond just speech.

“The Defendant had a right, like every American, to speak publicly about the election and even to claim, falsely, that there had been outcome-determinative fraud during the election and that he had won,” the indictment states.

Trump has called the indictment from a probe led by special counsel John L. “Jack” Smith a political “witch hunt” for criminalizing his claims of victory in 2020 and taking out the leading candidate for the 2024 Republican presidential nomination.

And on his social media platform, the former president boosted videos of commentary that focused on the idea that he was being charged for what he said.

That included Sen. Tom Cotton, R-Ark., in a Fox News interview Wednesday. “These are all constitutionally protected activities in which former President Trump engaged, political activities and free speech protected by the First Amendment,” Cotton said.

Sen. Marco Rubio, R-Fla., posted on X, formerly known as Twitter: “Apparently it is now a crime to make statements challenging election results if a prosecutor decides those statements aren’t true.”

Ilya Somin, a law professor at George Mason University, said the Trump case rests on Trump’s actions, not his longtime unfounded claims of electoral fraud.

“Trump went beyond simply saying the election was stolen from him. He and his co-conspirators had a specific plan to impede certification of the election,” Somin said. “That’s different from the guy who sits on a barstool or even the guy who goes on TV and says, ‘Well, I think the election was stolen.’”