President Joe Biden said Thursday that he supports changing Senate filibuster rules to pass a bill codifying abortion rights.

“I believe we have to codify Roe v. Wade into law, and the way to do that is to make sure that the Congress votes to do that and if the filibuster gets in the way [there] should be … an exception,” Biden told reporters during a news conference in Madrid, where he is attending a NATO summit.

Senate filibuster rules require that most legislation, including any related to abortion rights, have support from at least 60 senators to move forward. The 100-seat chamber is currently evenly split between the two parties, with Vice President Kamala Harris as the tiebreaker.

Biden’s administration is sorting out how to respond to the Supreme Court’s decision recently in Dobbs v. Jackson Women’s Health Organization, which overturned the court’s 1973 ruling in Roe v. Wade. The decision means that abortion access is no longer federally protected up until the point of fetal viability, generally 22 to 24 weeks gestation.

The legality of abortion is now up to the states. As of Thursday morning, five states had total abortion bans in place, and several more have bans that could take effect pending legal challenges. Additional states have six-week bans in place that make it challenging to seek abortion care because it is so early patients may not know they are pregnant.

Democrats are in control of both the House and the Senate, but the Women’s Health Protection Act (WHPA), which would have codified abortion access, failed twice in the Senate after passing the House. It is unclear whether the WHPA could pass with 50 votes since Democratic Sen. Joe Manchin of West Virginia voted against it. Republican Sen. Susan Collins and Democratic Sen. Tim Kaine are working on a narrower bill that might have a better chance of receiving bipartisan support.

Many Democrats have urged Biden to use his executive authority to protect abortion access by providing travel vouchers for people in states with restrictive abortion laws and even opening clinics on federal land. Biden, however, has said his options to protect abortion access are limited and that the best path forward is for Congress to pass a law replacing Roe. He has also supported a filibuster carveout for voting rights legislation, which didn’t get through the Senate.

All 50 Democrats would need to back a filibuster change, and it’s not clear whether they do. Manchin and Sen. Kyrsten Sinema of Arizona are among those who have said they do not want to pursue filibuster changes more generally. Sinema supports Roe but not changing the filibuster to protect abortion rights because she says it would also be easier to restrict access when Republicans are in control. She has also pointed out that the filibuster has stopped Republicans from passing other restrictive abortion laws in the past.