Democratic California Gov. Gavin Newsom has signed legislation banning local governments from requiring voters to present an ID at the ballot box in order to cast a vote – a move which sparked backlash from Elon Musk, who branded Newsom as "The Joker."

"Wow, it is now illegal to require voter ID in California! They just made PREVENTING voter fraud against the law," Musk wrote on X late Monday. "The Joker is in charge."

The bill was passed by the California Assembly in August after being introduced earlier in the year by state Sen. David Min, a Democrat. Newsom signed the bill into law on Thursday. 

NEWSOM SIGNS ELECTION 'DEEPFAKE' BAN, MUSK CLAPS BACK RESHARING AI-ALTERED VIDEO OF KAMALA HARRIS

Elon Musk speaks

Elon Musk, co-founder of Tesla and SpaceX, called Gov. Gavin Newsom "The Joker" in a post over voter ID requirements.  (Apu Gomes/Getty Images)

The new law was in response to the beachside city of Huntington Beach passing a voter ID amendment, Measure A, in March with the support of a majority of residents which would allow the city to require voter identification, increase in-person voting sites, and monitor ballot drop boxes in local elections. The measure won at the polls in March with 53.4% approval, county election data shows.

But Attorney General Rob Bonta and California Secretary of State Shirley N. Weber challenged Huntington Beach’s voter ID law, which would have amended the city’s charter to allow voter ID requirements by 2026.

In their lawsuit, Bonta and Weber argued that the city’s voter ID law "unlawfully conflicts and is preempted by state law." 

California is one of 14 states that does not require voter ID at the polls, according to the National Conference of State Legislatures.

"The right to freely cast your vote is the foundation of our democracy and Huntington Beach’s voter ID policy flies in the face of this principle," Bonta said in a statement earlier this year. 

He argued that state elections already contain "robust voter ID requirements with strong protections to prevent voter fraud." He said the new requirements would disproportionately burden "low-income voters, voters of color, young or elderly voters, and people with disabilities." 

AG GARLAND PLEDGES TO FIGHT VOTER ID LAWS, ELECTION INTEGRITY MEASURES

Newsom

Newsom signed a bill banning local governments from requiring voters to present an ID at the ballot box in order to cast a vote. (Myung J. Chun/Los Angeles Times via Getty Images)

While that lawsuit made its way through the courts state, Min introduced Senate Bill No. 1174. It passed out of the State Assembly in a 57-16 vote and in the State Senate in a 30-8 vote.

The Huntington Beach City Council placed the voter ID measure on the March ballot after taking a series of hotly contested decisions on topics ranging from flag flying to the removal of books from the public library's children's section over concerns about the appropriateness of materials. The moves were initiated by a politically conservative council majority, which took office in 2022, and have drawn scores of residents on all sides of issues to city meetings.

Huntington City Attorney Michael Gates said in March that the passage of the amendment approved by voters was "not only permissible" but backed by the state constitution. 

Last week he vowed to continue to enforce Measure A. 

"That bill means nothing to the city of Huntington Beach," Michael Gates said, per OrangeCountyLawyers.com. "The city is going to proceed with its voter ID laws because it has a constitutional right to do so."

Musk’s outburst is not the first time he has sparred with Newsom.

Musk last month encouraged his 198 million X users to share an AI-doctored video of Vice President Kamala Harris after Newsom signed a bill into law banning digitally altered political "deepfakes."

Musk said he also plans to move the California headquarters for SpaceX to Texas after Newsom signed a bill into law that will bar school districts from requiring teachers to notify parents if their child uses different pronouns or identifies as a gender that's different from what’s on school records.

CLICK HERE TO GET THE FOX NEWS APP

The Joker dancing

Joaquin Phoenix in a scene from "Joker."  (AP/Warner Bros. Pictures)

The Space X owner has also said Democratic states are gaining an unfair advantage over red states in elections as a result of illegal immigration since the census is based on a simple headcount of all residents, both legal and illegal. He said congressional representation and electoral votes are apportioned based on all residents instead of just focusing on citizens.

Musk has often weighed in on voter integrity and immigration matters, writing on X in March that "failure to require photo ID to vote obviously makes it impossible to prove voter fraud. That is why the far left refuses to require photo ID to vote."

Fox News’ Bradford Betz contributed to this report.