Oklahomans voted to legalize medical marijuana throughout the state Tuesday night, creating some of the least restrictive laws for the drug in a staunchly red state.

State Question 788 passed around 10:30 p.m. EST with 56.7 percent of the vote and 89 percent of precincts reporting, according to The New York Times. (RELATED: Gallup: American Support For Legal Marijuana At All-Time High)

The new law allows doctors to prescribe marijuana to anyone over the age of 18. Growing, selling and using marijuana is now legal, as long as it is done for medical purposes, according to Business Insider.

Groups opposed to the legislation spent close to $1 million campaigning against the initiative. Pot opponents faced an uphill battle, though, as polling showed a large margin of support for the proposed law in the lead-up to the vote.

Oklahoma is the 30th state to legalize marijuana for medical purposes, BI reported.

Oklahoma reclassified all drug possession crimes as misdemeanors in 2016, reducing the punishment for offenders caught with the illegal substance. Law enforcement opposed State Question 788 and a further relaxing of state drug laws, but they could not sway the vote, according to Fortune.

Follow Tim Pearce on Twitter

Content created by The Daily Caller News Foundation is available without charge to any eligible news publisher that can provide a large audience. For licensing opportunities of our original content, please contact licensing@dailycallernewsfoundation.org.