They are not normally a good thing, but some can be beneficial.
The Malayan mud snail feeds on detritus present in the substrate,
while Ramshorns graze on slime and hair algae.
A common one to avoid are the small brown ear-shelled snails,
that, if allowed to overpopulate will destroy all your plants.
To cope with increasing snail populations people add Loaches which
feed off snails. Puffers are also great snail killers but don't do well in
aquaria.
To be honest, snails can be more trouble than they're worth, unless you
buy one of the larger algae grazing snails such as nerite snails, then they
should be something to avoid.