The official way to use copyrighted music on YouTube is through YouTube Studio > Audio library. The audio library includes free music and sound effects, some of which don't even require attribution.
Not long ago, Fred Armisen was reminiscing about the sound-effect LPs he used to stock at the Chicago record store where he worked in the Nineties. These vinyl platters contained all kinds of sounds, ...