The 5-4 ruling said the Partial Birth Abortion Ban Act that Congress passed and President Bush signed into law in 2003 does not violate a woman's constitutional right to an abortion.
Click here to read the full Partial Birth Abortion Ban Act.
The opponents of the act
"have not demonstrated that the Act would be unconstitutional in a large fraction of relevant cases,"Justice Anthony Kennedy wrote in the majority opinion.
The decision pitted the court's conservatives against its liberals, with President Bush's two appointees, Chief Justice John Roberts and Justice Samuel Alito, siding with the majority.
Justices Clarence Thomas and Antonin Scalia also were in the majority.
It was the first time the court banned a specific procedure in a case over how, not whether, to perform an abortion.
Abortion rights groups have said the procedure sometimes is the safest for a woman. They also said that such a ruling could threaten most abortions after 12 weeks of pregnancy, although government lawyers and others who favor the ban said there are alternate, more widely used procedures that remain legal.
The outcome is likely to spur efforts at the state level to place more restrictions on abortions.
More than 1 million abortions are performed in the United States each year, according to recent statistics. Nearly 90 percent of those occur in the first 12 weeks of pregnancy, and are not affected by Wednesday's ruling.
The procedure at issue involves partially removing the fetus intact from a woman's uterus, then crushing or cutting its skull to complete the abortion.
Abortion opponents say the law will not reduce the number of abortions performed because an alternate method, dismembering the fetus in the uterus, is available and, indeed, much more common.