Republicans around the country railed against President Obama's health-care law for four years, but in recent weeks, GOP governors and state legislators have embraced some of the bill's provisions.

How did Republicans learn to stop worrying and love Obamacare?

In a word: industry.

Hospitals, insurers and drug companies have lobbied in state capital after state capital, leaning on Republicans until they agreed to create insurance exchanges or expand Medicaid as Obamacare prescribed.

Idaho has a Republican governor and a Legislature dominated by Republicans, which makes it noteworthy that the state is on the verge of creating an Obamacare exchange.

An exchange is a federally regulated and subsidized virtual marketplace for individuals to buy health insurance. Under Obamacare, states must create these exchanges, or the federal government will.

Oklahoma is forging a third path: Gov. Mary Fallin has refused to set up an exchange, and Attorney General Scott Pruitt is suing to block the federal government from establishing one.

But Idaho Gov. Butch Otter supports a state exchange, arguing that otherwise Idaho would "be at the federal government's mercy in how that exchange is designed and run." But setting up a state exchange doesn't change that.

Obamacare gives the U.S. secretary of health and human services power to impose on exchanges "such ... requirements as the Secretary determines appropriate." A forthcoming Cato Institute report on the exchanges says Obamacare "empowers the secretary to require state-funded exchanges to operate exactly as she would operate a federal exchange."

So why would Idaho Republicans create this exchange instead of following Oklahoma's lead? One driving cause has been the business lobby -- specifically the health-care lobby.

"They lobbied greatly," Idaho state Sen. Monty Pearce, a Republican exchange opponent, told me about the health care sector and the legislation to create the insurance exchange. "They've been lobbying on it for a couple of years. ... They've hired every lobbyist they can get."

The Idaho Hospital Association has made a state exchange a priority while also lobbying to expand Medicaid. Another leading exchange backer is the Idaho Association of Commerce & Industry -- one of the biggest-spending lobbying organizations in Boise. Dozens of Idaho businesses, led by insurers and health-care providers, formed the Idaho Health Exchange Alliance to back Otter's push for an exchange.

These pro-exchange health-industry companies also poured money into legislative campaigns. Comb through the campaign finance disclosures of most Idaho state senators and you'll see gifts from drugmakers (GlaxoSmithKline and Pfizer), insurers (Blue Cross of Idaho and PacificSource Health Plans) and industry groups (Idaho Hospital Association, the Pharmaceutical Research and Manufacturers of America, and the Idaho Health Care Association). All these companies benefit from a state-run exchange.

Pearce thinks this industry push helped persuade Republicans to overcome their general opposition to Obamacare and big government.

What do the companies stand to gain? Insurers and providers both benefit from the federal subsidies that come with a state exchange. Insurers also get protection from competition: Stricter rules keep out new entrants, and some supporters made explicitly protectionist arguments. For example, Sen. John Goedde, an insurance agent, argued that "Idaho's insurance industry would lose out under a federal exchange, which likely would focus on national companies rather than Idaho insurers," as the Idaho Spokesman-Review paraphrased it.

In other states, the Obamacare drama plays out the same way.

In Ohio, Republican Gov. John Kasich recently announced he would expand Medicaid as prescribed -- but not required -- by Obamacare. "We have been actively involved" in pushing this expansion, Cleveland Clinic top lobbyist Oliver Henkel told my Washington Examiner colleague Philip Klein. The clinic reached out early on to Kasich's administration and helped win them over.

One Columbus lobbyist told me that the hospitals were the driving force behind convincing Republicans.

In Missouri, the Medicaid Expansion Coalition includes the Missouri Hospital Association, Missouri Association of Health Plans, the Missouri Chamber of Commerce and many local chambers. Patrick Ishmael of the conservative Show-Me Institute told me in an email, "[I]t's pretty clear in my conversations that Chamber support for the expansion is weighing on conservative legislators."

This is a familiar story. Republicans tend to drop their opposition to big government when big business pushes them hard enough. We've seen it in Washington: The two biggest expansions of government under President George W. Bush were the 2008 Wall Street bailout and the 2004 expansion of Medicare to cover prescription drugs -- both of which had firm business support.

Obama always had the hospitals and drugmakers on his side in passing Obamacare through Congress. Now these industries are pushing the law through state capitals, too.

Timothy P. Carney, The Examiner's senior political columnist, can be contacted at tcarney@washingtonexaminer.com. His column appears Monday and Thursday, and his stories and blog posts appear on washingtonexaminer.com.