After two failed attempts, the Virginia Senate on Monday passed a state budget that includes tens of millions of additional dollars for public schools, health care and transportation, including $300 million for the Metrorail extension to Dulles Airport.

But the evenly divided chamber rejected an attempt by Democrats to force the state to pay $1.5 million a year for a Republican-supported law that will require women to undergo ultrasounds before abortions.

The Senate’s 35 to 4 vote paves the way for the General Assembly, in the second week of a special session, to pass the two-year, $85 billion spending plan. Two Democrats joined two Republicans in rejecting the proposal.

“After a long, arduous partisan process, I’m relieved we passed a budget with a bipartisan vote,’’ Senate Majority Leader Thomas K. Norment (R-James City) said.

Now, a dozen negotiators appointed by legislative leaders to hammer out a budget compromise during the special session — Republicans and Democrats, delegates and senators — will begin to hash out an agreement between the two chambers. All 140 legislators will vote on the budget after the negotiating team reaches a deal.

“We’re pleased we got Virginians a budget that restores millions of dollars to support school children, ensures families won’t be hit with budget-busting tolls, repairs the safety net for the most vulnerable Virginians, and gets some relief for homeowners hurt by the foreclosure crisis,” said Sen. A. Donald McEachin (D-Henrico).

Failure to pass a budget by July 1, the start of the fiscal year, could result in a partial government shutdown for the first time in Virginia history. Senate Democrats had voted down two budgets and threatened to scuttle a third after Republicans rebuffed their request for increased spending in certain areas and more power on committees.

The breakthrough came last week when Republicans agreed to fund more Democratic priorities and Democrats agreed to divorce their demand for more power in the chamber from the budget process. The Senate is evenly divided between the two parties, and Lt. Gov. Bill Bolling (R) can break tie votes, except on the state budget.

The Senate blueprint restores $1 million to poison-control centers and $455,000 for teen pregnancy prevention across the state as well as money for nursing homes, child-care services and programs that help people with physical disabilities find employment.

It provides an additional $60 million to help schools hire staff in the expensive Northern Virginia job market. The House budget includes $24 million for the so-called cost-to-compete money.

The Senate version includes an estimated $100 million — to be financed by bonds — to delay the imposition of tolls in Hampton Roads, pay for 10 vacant judgeships and a 2 percent raise for state employees, and restore a $500,000 cut to public broadcasting.

It directs Virginia’s share of the federal mortgage settlement to localities to be spent on schools, specifically K-12 education, pre-kindergarten programs and inflation expenses, and to a housing trust fund.

The plan makes cuts in the budget to pay for increased spending — including $20 million from a fund Gov. Robert F. McDonnell (R) proposed to prepare for potential federal cuts.

The most passionate debate on Monday occurred when Democrats tried to require the state to pay for ultrasounds before abortions.

“This has nothing to do with abortion,’’ Senate Minority Leader Richard L. Saslaw (D-Fairfax) said. “We are dealing with a mandate.”

Said Sen. Jeff McWaters (R-Virginia Beach): “This is about the sanctity of human life.’’

The amendment died 19-20 with Sen. Charles Colgan (D-Prince William) voting with the Republicans; Sen. Jill Vogel (R-Winchester) was absent. A similar proposal failed during the regular session.