The Pennsylvania Supreme Court granted a three-day extension for mail-in ballots in the November election – allowing votes to count in the battleground state even if they arrive a little late.

The state traditionally required mail-in ballots to be due by the time polls close on Election Day.

Now ballots will be counted if they're received by 5 p.m. on Nov. 6 -- as long as they're postmarked by 8 p.m. on Election Day, according to the court’s order.

BARR SAYS RUMORS TRUMP WOULD REFUSE TO LEAVE OFFICE IF HE LOSES ELECTION ARE 'CRAP'

The Supreme Court noted its ability to grant the new mail-in measures because of language in Pennsylvania’s Election Code, which states that courts have the “authority to provide relief when there is a natural disaster or emergency,” in order to allow residents to exercise their right to vote.

The ruling was in response to the state Democratic Party suing for a deadline extension.

The decision comes amid a national controversy involving the efficiency of the U.S. Postal Service and ira ability to cope with an expected increase of mail-in ballots due to the coronavirus pandemic and interest in the presidential election.

The court’s decision is seen as a win for Democrats as President Trump and other Republicans have been floating the idea that mail-in ballots can be subject to fraud and will invalidate the election’s results.

“Unsolicited Ballots are uncontrollable, totally open to ELECTION INTERFERENCE by foreign countries, and will lead to massive chaos and confusion!” Trump tweeted Thursday.

Though the social media platform flagged his message with a blue exclamation mark, which warns of “misleading” content and directs the viewer to a link that says, “Learn how voting by mail is safe and secure.”

TRUMP SLAMS NEVADA GOVERNOR, CLAIMS 'HE'LL CHEAT ON THE BALLOTS'

Pennsylvania is not the only state that will permit votes to be counted after the polls close on Election Day.

Eighteen other states and the District of Colombia have traditionally permitted a grace period to count votes after the polls close -- 10 of which went Republican in the last presidential election.

Iowa, North Carolina, Texas and Pennsylvania are all swing states that voted red during the 2016 presidential election, and permit postmarked ballots that arrive after Election Day.

CLICK HERE TO GET THE FOX NEWS APP 

Though Trump won Pennsylvania in 2016, the margin over opponent Hillary Clinton was slim. Before electing Trump in the last presidential race, Pennsylvania had not voted for a Republican since Ronald Regan in 1988.

The court also declared Thursday, that ballot drop boxes are legal and therefore permitted throughout the state.

The ruling will likely anger some Republicans as the Trump campaign had previously sued unsuccessfully in federal court to block drop boxes nationally.