Elon Musk speaks at a town hall-style meeting in Pennsylvania on Thursday in support of Donald Trump. The CEO of Tesla and SpaceX is offering registered voters in Pennsylvania $100 to sign a petition backing the First and Second Amendments. Anna Moneymaker/Getty Images

Billionaire Elon Musk is offering Pennsylvania registered voters $100 to sign a pro-Donald Trump petition backing the First and Second Amendments.

"If you're a registered Pennsylvania voter, you & whoever referred you will now get $100 for signing our petition in support of free speech & right to bear arms. Earn money for supporting something you already believe in!," Musk wrote on X, the social media platform he bought two years ago for $44 billion when it was known as Twitter.

"Offer valid until midnight on Monday," the founder of SpaceX and Tesla said.

In a separate posting, Musk notes that "to minimize fraud" checks will be mailed to a person's voter address on file in Pennsylvania.

Musk, the world's richest man who has contributed $75 million to the pro-Trump America PAC he founded and has appeared recently with the former president at a campaign rally in Pennsylvania, linked to the petition.

"The First and Second Amendments guarantee freedom of speech and the right to bear arms. By signing below, I am pledging my support for the First and Second Amendments," says the petition being circulated to Musk's 200 million followers on X.

It also said that "in appreciation for your support, you will receive $47 for each registered voter you refer that signs this petition."

The goal is to get a million registered voters in seven swing states to support the U.S. Constitution, "especially freedom of speech and the right to bear arms."

The offer is only good for registered voters in Pennsylvania, Georgia, Nevada, Arizona, Michigan, Wisconsin and North Carolina.

And the offer expires on Oct. 21. the deadline for voter registration.

It's illegal to pay someone to vote, but not illegal to compensate someone for signing a petition or trying to get other people to sign.

Brendan Fischer, a campaign-finance lawyer, told the New York Times that Musk's offer appears to be within the law.

"The fact that they are only paying the referrer rather than the signatory further insulates the PAC from any accusations that they are buying votes," Fischer said. "Ultimately, what America PAC is doing here is spending money for voter data, which PACs and campaigns do all the time."