The Maryland Senate gave final passage to the measure, on a vote of 47 to 0, during a Saturday session in advance of Monday’s scheduled adjournment.

Maryland will join more than three-dozen other states that allow wine shipment from vineyards to consumers. Maryland residents will be able to order up to 18 cases of wine per-year, per-household

The governor, who favors Guinness over Chardonnay, has said he would sign the bill.

The powerful alcohol industry had long resisted efforts to legalize direct wine shipment in Maryland. This year, representatives from the industry for the first time agreed to a compromise that allows shipments from vineyards, but not from out-of-state retailers or on-line specialty Web sites as some consumers had hoped.

Momentum for the measure comes after wine connoisseurs in Maryland became more organized in their lobbying efforts, and follows a study by the state comptroller that dispelled concerns from opponents that such a measure would make it easier for minors to access alcohol.

For years, scores of residents in the Washington suburbs have tried to get around the prohibition by sending bottles to their offices in the District or to the homes of friends in D.C. and Virginia, which allow direct shipment.