I would say it because of the erosion of the enamel by its carbonated acid, but is it really the case?
From "Modern Food Microbiology" by James M. Jay, Martin J. Loessner and David A. Golde:
The pH of non-carbonated water should be around neutrality, whereas that of carbonated water is typically between 3 and 4 - ideally at or below pH 3.5.
Which means that drinking carbonated water lowers general pH in your mouth and when it gets lower than some critical value (estimated to be around 5.5 but which in fact can be very individual) tooth enamel begins to demineralize. Additionaly, low pH is a good environment for some species of bacteria which produce even more acid.
Also, one may think that it is safe to hold carbonated water in mouth. After all isn't all water safe? Carbonated water is not safe because of its low pH and so proper drinking method should be used, see: "Influence of drinking method on tooth-surface pH in relation to dental erosion".
If it is just sparkling water, not other acids –aka flavours– added, then it is not that bad for your teeth. It all depends on how acidic, how low the pH level for the actual drink is and for how long it comes into contact with your teeth. The amount of time your teeth are in contact with it is typically low. Carbonic acid does not stick to your teeth. And this acid is very weak with minimal impact on teeth altogether.
It is impossible to draw a general conclusion to all waters on the market.
But for anyone still worried, there are two factors at play:
- Actual amount of CO2 added
- Presence of other minerals which can buffer the acidity
Wikipedia gives you for example a pH level of 3-4. Classifying it between apple and orange juice. That sounds quite scary and very acidic. Pictures of karst erosion come to mind immediately.
However, this is not necessarily the actual pH level of bottled sparkling water in every case. Excuse the ads, but for reference: several mineral waters on sale have much less acidity. Here is one with an actual pH of between 4 and 5 and here is one with pH of ~5.7 and one with very low bubble count with a pH of 6!
Therefore you have to look for the actual product, ask the manufacturer or test the water in question yourself. In the case of homemade soda this the only option anyway.