The invention relates to a method for preparing silicone resins (S) containing hydroxy groups and alkoxy groups, wherein 100 parts by weight of alkoxysilane, 0.01 to 1 part by weight of hydrocarbon containing 10 to 2000 ppm by weight of Cl relative to the alkoxysilane, and water are reacted for at least 30 minutes at a minimum of 50°C without using any additional organic solvents of which a maximum of 1 percent by weight is water-soluble at 0.1 MPa and 20°C.