How to record system audio on a Mac?

I'm using MacOS Monterey in an Imac 2020. I need to record the sound the system is playing at the moment. For instance, if i'm watching a video on Youtube, i want to record the video audio. How can i do it ?

I know how to record using the microphone in Quicktime, but the quality sucks as it will get environment noise too.

I tried the approach Quicktime + Blackhole as described on the link below, but it did not work ; when i try to record with Quicktime selecting the Blackhole source and playing something on the computer, it won't record anything just silence.

https://blog.accusonus.com/recording-sound-for-video/record-screen-audio/


Solution 1:

If you can't persuade the freeware options to work - Soundflower & the new kid on the block Black Hole, then look to established competitors...

I'm a long-time user of these products, since they were first forked from the original SoundFlower more than a decade ago.

They're not free, but have been solid [& constantly updated] since day one.

I'm talking about Audio Hijack & its little brother Piezo