The measure approved Thursday requires companies with more than 10,000 Maryland employees to spend at least 8 percent of their payroll on employee health care or pay the difference into the state-supported Medicaid program. Of the state's large employers, only Wal-Mart spends less than 8 percent on health care.
Labor unions, who heavily pushed for the bill, said they would pursue similar legislation in at least 30 other states, focusing first on Colorado, Connecticut and Washington.
"The tide is turning because working people are not just fed up they are ready to get active to set our country in a different direction, one state at a time," AFL-CIO President John Sweeney said in a statement.
Maryland's Democratic-controlled Legislature overrode a veto by Republican Gov. Robert Ehrlich.
Critics of the legislation called it a dangerous precedent that ultimately would cost Maryland jobs.
The company employs about 17,000 Maryland residents at more than 40 Wal-Mart and Sam's Club stores, and about 1.3 million people nationwide.
A Wal-Mart executive called the bill a poorly worded mandate for a single company. Mia Masten, a director of corporate affairs, said the bill "could be the beginning of a slippery slope."
"We believe everyone should have access to affordable health insurance, although this legislation does nothing to accomplish that," said Masten, who said the retailing giant may partially pull out of the state if the bill becomes law.
She said Wal-Mart was unfairly singled out because of "partisan politics" and that Medicaid's problems go beyond the behavior of one company.
"This does nothing to accomplish this goal of providing everyone access to affordable health care insurance," said Sarah Clark, a spokeswoman for the Bentonville, Ark.-based company.
A spokesman for Ehrlich said the governor was disappointed in the vote and that it may put in jeopardy a planned Wal-Mart distribution center slated for Maryland's Eastern Shore.