The 240-194 vote on an amendment by Rep. Bart Stupak, D-Mich., was a blow to liberals, who would have allowed the Obama administration and its successors to decide whether abortions would be covered by the government plan.
Sixty-four Democrats joined 176 Republicans in favor of the prohibition.
Stupak's measure also would bar anyone getting federal health subsidies from purchasing private insurance polices that included abortion coverage.
"Let us stand together on principle - no public funding for abortions, no public funding for insurance policies that pay for abortions," Stupak urged fellow lawmakers before the vote.
The amendment would bar the new government insurance plan from covering abortions, except in cases of rape, incest, or where the life of the mother is in danger. The Democrats' original legislation would have allowed the government plan to cover abortions, if the Health and Human Services secretary decided it should.
The amendment also would prohibit people who receive new federal health subsidies from buying insurance plans that include abortion coverage.
The Democrats' original bill would have allowed people getting federal subsidies to pay for abortion coverage with their own money. Abortion opponents dismissed that as an accounting gimmick.
Abortion rights advocates called the measure the biggest setback to women's reproductive rights in decades. Anti-abortion Democrats forced House leaders to bring it up for a vote by threatening to oppose the underlying bill, and efforts to reach a compromise fell apart Friday night.
"Like it or not, this is a legal medical procedure and we should respect those who need to make this very personal decision," said Rep. Diana DeGette, D-Colo.
Some Republicans considered voting "present" in hopes that might unravel support for the underlying health care bill among anti-abortion Democrats, but only one did, Rep. John Shadegg, R-Ariz.
"If I felt that the (health overhaul) bill could be killed by not advancing the Stupak amendment then it seems it would be prudent to vote in such a way that wouldn't advance the bill, but it doesn't appear that that's a possibility," Rep. Michele Bachmann, R-Minn., said before the vote.
The National Right to Life Committee and the U.S. Conference of Catholic Bishops lobbied lawmakers in both parties on the abortion measure. The bishops said they would oppose the bill if it lacked a strict prohibition on any federal funding for abortions.
Stupak's language applies to policies sold in a federally regulated insurance exchange that would be set up in 2013. The overhaul bill envisions both private companies and the government offering policies in the exchange.
Under the Stupak amendment, people who do not receive federal insurance subsidies could buy private insurance plans in the exchange that includes abortion coverage. People who receive federal subsidies could buy separate policies covering only abortions if they use only their own money to do it.
Companies selling insurance policies covering abortions would be required to offer identical policies without the abortion coverage.
Abortion-rights supporters say private insurers will not likely offer policies with abortion coverage in the exchange because many potential buyers will be getting federal subsidies and therefore wouldn't be able to purchase them.
Around 21 million people are expected to get coverage through the exchange by 2019, according to the Congressional Budget Office.
The majority of Americans who get their insurance coverage from their employers would not be affected.
Abortion-rights supporters say the restrictions in the amendment go further than current law.
A law called the Hyde amendment - which must be renewed annually - bars federal funding for abortion except in cases of rape, incest or if the mother's life is in danger. The restrictions apply to Medicaid, forcing states that cover abortions for low-income women to pay for them with state revenues. Separate laws apply the restrictions to the federal employee health plan and the military.
Currently abortion coverage is widely available in the private market. A Guttmacher Institute study found that 87 percent of typical employer plans covered abortion in 2002. A Kaiser Family Foundation survey in 2003 found that 46 percent of workers in employer plans had abortion coverage. The studies asked different questions, which might help explain the disparity in the results.
Abortions in the first trimester typically cost between $350-$900, according to Planned Parenthood.
A health overhaul bill pending in the Senate also bars federal funding for abortion, but the language is less stringent. Discrepancies between the House and Senate measures would have to be reconciled before any final bill is passed.
By Associated Press Writer Erica Werner