The lower Court of Common Pleas ruled on Friday against the Trump campaign which sought to invalidate 8,329 ballots in Philadelphia, the state's biggest city, because envelopes lacked information such as printed names, the date or addresses.
The campaign has not alleged the ballots were fraudulent.
President-elect Joe Biden, the Democratic challenger, won Pennsylvania by a margin of around 82,000 votes, according to Edison Research.
A decision by the Pennsylvania Supreme Court would likely impact ballots across the state, although the number was unclear.
In a separate case likely to be affected by a Supreme Court decision, Nicole Ziccarelli, a Republican state senate candidate said in court papers she was seeking to invalidate 2,349 ballots in Allegheny County, which includes Pittsburgh, because envelopes lacked dates.
The Trump campaign has been fighting several lawsuits trying to overturn Pennsylvania's election outcome, which will be critical if the president hopes to succeed in his long-shot bid to reverse the election. The president has claimed without evidence the election was stolen but his campaign not scored a significant victory in court.
On Tuesday, a federal judge overseeing a separate case expressed skepticism of the campaign's request to block officials from certifying Biden's victory in Pennsylvania.In another Trump lawsuit, the Pennsylvania Supreme Court ruled against the campaign on Tuesday and said Philadelphia officials acted reasonably in keeping Trump observers behind barricades and 15 feet (4.5 m) from counting tables.