Governor Scott Walker of Wisconsin, a prominent candidate in the Republican presidential campaign, signed a bill on Monday that outlaws non-emergency abortions at or beyond 20 weeks of pregnancy in his state.

Abortion is a core issue for the conservative Republican base whose support Walker will seek as he vies in a crowded presidential field that also includes Jeb Bush, Marco Rubio and Donald Trump.

It is also an issue in which he could be targeted by rivals: just nine months ago he ran a television ad during his gubernatorial re-election campaign in which he said whether to obtain an abortion was a decision to be taken between a woman and her doctor.

Under the new law, doctors who perform an abortion at or after 20 weeks in non-emergency situations could be charged with a felony punishable by up to $10,000 in fines and three and a half years in prison. Doctors could also be sued for damages.

No exception is made for pregnancies resulting from rape or incest. Doctors would be allowed to perform abortions beyond 20 weeks only if the mother was likely to die or suffer irreversible injuries within 24 hours.

The law’s supporters say fetuses can feel pain after 20 weeks. They say the ban will spare those unborn children an excruciatingly painful death.

The American Congress of Obstetricians and Gynecologists, however, says fetuses cannot feel pain until the third trimester starts at 27 weeks.

Scott Walker cites the Wisconsin abortion bill in his campaign announcement. Guardian

“When an unborn child can feel pain I think most people feel it’s appropriate to protect that child,” Walker told reporters after signing the bill.

The Democratic National Committee condemned the new law, saying it will hurt women.

The 1973 supreme court decision in Roe v Wade established a nationwide right to abortion but allowed states to restrict the procedures after the fetus reaches viability, the point at which it could survive outside the womb.

The ruling offered no legal definition of viability but said it could range from the 24th to 28th week of pregnancy.