GOP Maine Sen. Susan Collins says she believes Roe v. Wade is settled law and that judges should respect such precedents — possibly signaling that she could oppose a replacement for Justice Anthony Kennedy if President Trump’s Supreme Court nominee opposes that decision.

“I view Roe v. Wade as being settled law. It’s clearly precedent and I always look for judges who respect precedent,” Collins told reporters Wednesday.

Her comments came hours after the 81-year-old Kennedy — the longest-serving justice on the current court — announced that he would retire on July 31, giving Trump the opportunity to add another staunch conservative who could vote to overturn the landmark 1973 law that legalized abortion nationwide.

Collins and Alaska GOP Sen. Lisa Murkowski could be swing votes in the closely divided Senate, where Republicans have a 51-49 majority, which could shrink to 50-49 with Arizona Sen. John McCain at home battling brain cancer.

The GOP would only need 51 votes to confirm Trump’s nominee, and Vice President Mike Pence could jump in and cast the tie-breaker if either of the GOP women balks.

Trump said Wednesday he would make a choice from a list of 25 conservative, pro-life judges that he used to pick Neil Gorsuch, sparking concerns among Democrats and abortion rights advocates that Roe could be toast.

Murkowski issued a statement saying that Trump’s next Supreme Court pick could expect “exacting scrutiny.”

“It is my longstanding practice to carefully scrutinize the qualifications of judicial nominees and to cast an independent vote when judicial nominations come before the Senate,” Murkowski wrote in a tweet.

“There is no doubt that the President’s nominee to succeed Justice Kennedy can expect exacting scrutiny from the Senate and that is the standard I will apply in evaluating the nominee.”