The Massachusetts Senate has passed a wide-ranging health care reform bill that calls for the state to study the cost of a possible single-payer insurance system.

The Senate gave final approval to the measure on a 33-6 vote just before midnight on Thursday.

The 100-page bill seeks to limit price disparities between large Boston hospitals and smaller, community hospitals, and curb rising pharmaceutical drug costs.

Senators adopted an amendment that calls for the state to analyze what a government single-payer health system would cost Massachusetts, and compare those costs to the present market-based system.

The bill faces an uncertain road ahead.

The House is expected to draft its own, less expansive health care bill, and Republican Gov. Charlie Baker is questioning whether the Senate bill would save the state money.