Portugal's president has ratified a new law allowing abortion up until the 10th week of pregnancy, his office has said in a statement.
The new law brings the country in line with most of Europe
This brings the country into line with most of its European neighbours.
But President Anibal Cavaco Silva recommended that Parliament take further measures to ensure abortions are a last resort.
The country's parliament passed a law to legalise abortion on demand last month following a national referendum.
The vote failed to settle the issue in the mainly Roman Catholic country.
Last month 60% of voters backed the measure in a referendum, but the result was voided because of a low turnout.
Until the law change, abortions were allowed only in cases of rape or of a health risk to the mother.
Abortion is now banned in the EU only in Ireland, Malta and Poland.