The basic recommendation from The LEGO Group on cleaning your elements:
We recommend that you clean or wash your LEGO parts only by hand at max. 40°C or 104 degrees (F) Fahrenheit. Higher temperatures may affect the quality of the LEGO parts. You can add a mild detergent to the water, followed by rinsing with clear water. Please don't put your bricks in the washing machine or dishwasher or attempt to dry them in ovens, microwaves or with hair dryers. Any electrical parts, such as cables, motors, battery compartments, can only be wiped off with alcohol. Air-dry parts at room temperature. For disinfecting please use mild bleach.