After Colorado and Washington state legalized the sale of cannabis for recreational use, other states are weighing the pros and cons of following suit.

Colorado's economy has seen a boost since recreational marijuana sales became legal at the beginning of this year, and advocates elsewhere in the country are pushing state governments to go after the potential tax revenue the industry could bring. Voters in Alaska, Washington, D.C., Florida, and Oregon will decide on legalization at the polls in November.

According to the Colorado Department of Revenue's most recent data, the state made $7.4 million in marijuana taxes, licenses, and fees this past July. The state is predicting a total of $60 million to $70 million in tax revenue for the year.

What would the rest of the U.S. stand to make in taxes if voters were to choose to legalize pot? According to a new analysis by personal-finance website NerdWallet, it could mean a total of $3 billion each year. NerdWallet's findings are based on data on states' marijuana use and sales from the Substance Abuse and Mental Health Services Administration. 

On the top of the list of states would be California, which already has a medical marijuana program. If recreational marijuana were legalized, NerdWallet finds, the state could collect $519.3 million. That would almost be enough to cover the last year's budget for the California Department of Parks and Recreation.

In New York state, the study finds, legal weed could bring in between $100 million and $499 million. Texas, Florida, Illinois, Washington, Michigan, and Pennsylvania could reap similar windfalls.

Check out NerdWallet's infographic below.