If you leave the lid off your electric kettle and switch on, you can see what is happening.
The heating element quickly becomes covered with small silvery bubbles, each about 1 millimeter in diameter. These are air bubbles, forced out of solution by heat from the element.
Rough parts of the element’s metal surface provide nuclei for their growth and they eventually detach from the hot element and rise to the surface. These bubbles form and burst silently, and are clearly not the cause of the kettle singing.
After about a minute, the air bubbles are replaced by innumerable smaller bubbles of superheated steam that cling to the growth nuclei on the heating element.
A few seconds later, these primary steam bubbles become unstable.
As each bubble forms, its buoyancy tends to pull it away from the hot surface. Being surrounded by water which is still far below boiling point, the primary steam bubble suddenly condenses, collapsing implosively.
Curiously, the bubble does not vanish completely, but leaves behind a minute secondary bubble, presumably of water vapour, that does not immediately condense but is whirled away by the convection currents.
Soon there is such a cloud of these secondary bubbles that the water becomes turbid for half a minute or so.
Meanwhile, the shock waves transmitted through the water by the imploding primary bubbles produce a sizzling sound. You can give this sound a more definite pitch by temporarily replacing the kettle lid. This defines a volume of air above the water surface that resonates to some of the frequencies present in the shock waves.
Then, the cloud of secondary bubbles clears, and there is a general increase in the size of the primary steam bubbles that are still forming on the element. These are no longer forced to collapse immediately and implosively, since the surrounding water is now practically at boiling point, so the noise fades away.
As they grow, streams of buoyant primary bubbles detach themselves from the surface of the element, condensing in the cooler water a centimetre or so above it.
Within seconds, the water becomes hot enough to allow large detached primary bubbles to reach the surface, and now you can hear only the return of sound with the low gurgle of their bursting in the air cavity above the water.