A measure that would legalize medical marijuana in Arizona pulled ahead for the first time Friday, with both supporters and opponents saying they believed the proposal that went before voters on Election Day would pass.

Proposition 203 was ahead by 4,421 votes out of more than 1.63 million votes counted. The measure started out losing by about 7,200 votes on Nov. 2 and the gap gradually narrowed in the following 10 days.

Only about 10,000 early and provisional ballots remain to be counted in the state, and all are in Maricopa County.

If the measure passes, Arizona would be the 15th state with a medical marijuana law.

“We were optimistic that this is what the result was going to be today, and we’re thrilled that it came to reality,” said Andrew Myers, campaign manager for the Arizona Medical Marijuana Policy Project. “Moving forward it’s our responsibility to help implement a program that Arizona can be proud of.”

Opponents of the initiative, including all Arizona’s sheriff’s and county prosecutors, the governor, attorney general, and many other politicians, came out against the proposed law.

“All of the political leaders came out and warned Arizonans that this was going to have very dire effects on a number of levels,” said Carolyn Short, chairwoman of Keep AZ Drug Free, the group that organized opposition to the initiative. “I don’t think that all Arizonans have heard those dire predictions.

“Election night and this entire week has been a very exciting time for us – we just didn’t know we had actually lost,” Short said. “I am incredibly proud of our small but dedicated army of volunteers who worked very, very hard for months to educate voters about Prop 203.”

Backers of Proposition 203 argued that thousands of patients faced “a terrible choice” of suffering with a serious or even terminal illness or going to the criminal market for pot. They collected more than 252,000 signatures to put the measure on the ballot – nearly 100,000 more than required.