Last summer, Jennifer Knowles helped her three sons set up a lemonade stand in their Denver neighborhood. The proceeds would go to charity, while her kids, she thought, would learn about business, entrepreneurship and the satisfaction of making money.

And then the police showed up.

“Two police officers approached us and told us that we needed three permits to operate a lemonade stand,” she said. “We were literally across the street from our house, in our neighborhood, selling lemonade for charity, but even if we were on our sidewalk in front of our house, technically that would have been illegal too.”

It’s a surprisingly common situation. Lemonade stands run by children are technically illegal in 34 states, usually due to violation of health codes, child labor regulations or laws that require businesses to obtain permits. The laws don’t directly target lemonade stands, and in some cases are enforced somewhat loosely, usually prompted by a complain. But the result, from Maryland to Oregon, is the same: officials, usually police, telling children to take down their stands.