Philadelphia Court of Common Pleas Judge Angelo Foglietta did not immediately explain his reasoning, according to the AP.
Philadelphia District AttorneyLarry Krasnerfiled the civil action and argued that the sweepstakes giveaway was an illegal lottery.
The billionaire owner of X has been campaigning for Trump in the critical swing state.
Elon Musk photographed in June, 2024.Richard Bord/Getty Images
The sweepstakes also has reportedly drawn the attention of the Justice Department.
Federal law prohibits payment or offers of payment for registering to vote or to vote.
The judges written opinion has not yet been released.