It might be that nothing is actually being played, but opening an audio session wakes up your systems DAC/amplifier so you can hear the analog noise floor. In that case the noise is actually always there during playback, you're just more likely to notice it during silence.
Computers are a really hostile environment for audio, if possible you're always better off getting an external audio interface to put some distance between the analog signal path and any EMI spewing components.
I knew about OP's problem for years with discord's piece of shit webapp being the most egregious offender. For my system the sound falls into a low power state and there's an audible pop/click when something wakes it up. Even with the tab silenced and all notifications turned off it would still periodically do this. Other sites that used WebRTC had same problem but not as frequent. I think I worked around the issue eventually by disabling the automatic low power state at the expense of some additional battery consumption.
> Computers are a really hostile environment for audio
My first thought was the author should be happy that they don't live back in the bad old days of computing. Audible noise was the norm, even when you were playing audio. At least for PCs with sound cards. I don't recall the situation being quite as bad on other platforms. Modern PCs are much better on this front.
I have vague recollections of a quote from the Computer Chronicles in the mid-1990's. It went to the effect of turning a $2000 computer into a $200 stereo ...
This kind of thing amazes me. Radio is such a simple, yet omnipresent, technology that even something not made to listen to radio can accidentally catch and play the signal like an actual radio player would. I sure hope it's never going away.
When I was growing up, we lived within 6km line of sight from a powerful AM broadcaster on 660KHZ.
By some stroke of fortune, our woodstove smoke pipe and the tinfoil backed insulation of the house,
Along with the grounded base but rusty bolted on top of the woodstove created some kind of resonant receiver at that frequency. It would generate sufficient voltage to deliver the occasional electrical shock, which was very mysterious because we had no idea how this stove could shock you, even when the mains were turned off.
The mystery of the source of the power was shocks when we built a wire drying rack above the stove, which acted as a sound transducer. With the glove rack, we were treated to 24/7 programming, mostly community oriented stuff like “problem corner”(community issue discussion) bush relay messages for remote listeners outside of telephone reach, “tradio” (call in radio Craigslist, basically), news shows, talk shows, and some occasional music.
To me, it was just completely normal, never having known anything else besides electrocution hazard wood stoves and radio show mitten racks lol. It did fuel a fascination for electronics, though, so by the time I was seven I was an avid reader of popular electronics magazine. Forrest Mims. What a treasure of an engineer.
Computers are a really hostile environment for audio, if possible you're always better off getting an external audio interface to put some distance between the analog signal path and any EMI spewing components.