The U.S. Supreme Court on Monday ruled that business owners can object on religious grounds to a provision of President Barack Obama's healthcare law that requires closely held private companies to provide health insurance that covers birth control.

In a 5-4 vote on ideological lines, the justices said that such companies can seek an exemption from the so-called birth control mandate of the law known as Obamacare. The decision, which applies only to companies owned by a small number of individuals, means employees of those companies will have to obtain certain forms of birth control from other sources.

Hundreds of demonstrators on both side of one of the most contentious cases of the Supreme Court term converged on the court building, wearing costumes, chanting and carrying signs. Some demonstrators chanted, "Keep your boardroom out of my bedroom" and "Separate church and state, women must decide their fate." Signs carried by demonstrators offered contrasting views: "Obamacare - religious liberty First Amendment outlawed," "I am the pro-life generation," and "Birth control not my boss's business." One man dressed up as a copy of the Bible, brandishing a sign saying, "Use me not for your bigotry."

In a majority opinion by conservative Justice Samuel Alito, the court said the ruling applies only to the birth control mandate and does not mean companies would necessarily succeed if they made similar claims to other insurance requirements, such as vaccinations and blood transfusions.

In the majority opinion, Alito indicated that employees could still be able to obtain the birth control coverage via an expansion of an accommodation to the mandate that the Obama administration has already introduced for religious-affiliated nonprofits. The accommodation allows health insurance companies to provide the coverage without the employer being involved in the process.

Under the accommodation, eligible non-profits must provide a "self certification", described by one lower court judge as a "permission slip" authorizing insurance companies to provide the coverage. The accommodation is itself the subject of a separate legal challenge.

The government’s accommodation is “less restrictive than requiring employers to fund contraceptive methods that violate their religious beliefs," Alito wrote.

GINSBURG DISSENT

Justice Ruth Bader Ginsburg wrote a dissenting opinion on behalf of the liberal wing of the court.

"In a decision of startling breadth, the court holds that commercial enterprises, including corporations, along with partnerships and sole proprietorships, can opt out of any law ... they judge incompatible with their sincerely held religious beliefs," she wrote.

The justices ruled for the first time that for-profit companies can make claims under a 1993 federal law called the Religious Freedom Restoration Act (RFRA).

One of the two cases was brought by arts-and-crafts retailer Hobby Lobby Stores Ltd, which is owned and operated by David and Barbara Green and their children, who are evangelical Christians. The other case was brought by Norman and Elizabeth Hahn, Mennonites who own Conestoga Wood Specialties Corp in Pennsylvania.

None of the companies that have objected are publicly traded companies. Hobby Lobby has around 13,000 full-time employees while Conestoga Wood has 950.

The decision will affect similar cases brought by employers around the country. There are 49 cases in total, according to the Becket Fund for Religious Liberty. Religious institutions are already exempt from the requirement.

The company owners involved in litigation around the country do not all oppose every type of birth control. Some, including Hobby Lobby and Conestoga, object only to emergency contraceptive methods, such as Teva Pharmaceutical Industries Ltd's Plan B morning-after pill, and ella, made by the Watson Pharma unit of Actavis PLC.

THE WHITE HOUSE REACTS

The U.S. Supreme Court's ruling that some business owners are not required to provide birth control coverage to employees puts women's health at risk, the White House said on Monday, and called on Congress to make contraception widely available.

"Today's decision jeopardizes the health of women who are employed by these companies," White House spokesman Josh Earnest said at a briefing.

"We will work with Congress to make sure that any women affected by this decision will still have the same coverage of vital health services as everyone else," he said.

Earnest urged Congress to act to ensure that contraceptive care is widely available and said President Barack Obama would consider whether he can act on his own to ensure such coverage is available to all women.