• WANTED: Happy members who like to discuss audio and other topics related to our interest. Desire to learn and share knowledge of science required. There are many reviews of audio hardware and expert members to help answer your questions. Click here to have your audio equipment measured for free!

YouTube and YouTube Music, codecs and bit-rates used on Windows 10 and Android 10 Phones

M00ndancer

Addicted to Fun and Learning
Forum Donor
Joined
Feb 4, 2019
Messages
719
Likes
728
Location
Sweden
In a previous post here on ASR there was a discussion about lossless vs lossy bit-rate in audio.
Some of us only listen music using lossless codecs and others like myself listen to both lossless and lossy codecs.
So I got curious, what does YT Premium and YTM Premium actually use? Some formats I'm sure about, but not all. Time to test (Famous last word, this was a time sink).

But first a short background:
As a Google Play Music refugee, I'm was forced to move to YouTube Music Premium and YouTube Premium for my streaming needs or change streaming service.
I have no problem with that, it sound as good as Google Music did, even if here is differences in the codecs and bit-rates. In the early days GPM was using 320 kbps MP3 and later moved on to 320 kbps AAC (Not confirmed, haven't found any trustworthy links on AAC) and YouTube Music uses lower bit-rate AAC and Opus codecs.


Here are the results(long text, thanks @Tks for the reformatting suggestions):
(Reference links last in this post)

Video (No subscription)
  1. On Desktop using Windows10/Chrome/Youtube website: VP9
Audio (Plain old Youtube no subscription)
  1. On Desktop using Windows10/Chrome/YouTube website: Opus Variable Bitrate at ~160kbps, 48,000 kHz
Video (Youtube Music):
  1. On Desktop using Windows10/Chrome/Youtube website: AV1
  2. On the Desktop App: AV1
Audio (Youtube Music):
  1. On Desktop using Windows10/Chrome/Youtube website: AAC Variable Bitrate at ~256kbps, 44,100 kHz
  2. On the Desktop App: AAC Variable Bitrate at ~256kbps, 44,100 kHz
  3. On Android: AAC Variable Bitrate at ~256kbps, 44,100 kHz
Android extra features
The YTM App on Android has a few extra features not present on Windows 10
  1. In the app you can toggle between the song you are listening to and watch a corresponding video (and vice versa), with a few caveats.
  2. If you are listening to a song and Google don't find a corresponding video, then you can't toggle.
  3. If you are watching a video and Google can't find a song that matches, the video will be replaced with a still image playing the audio part with the same bit-rate.
  4. If Google finds the perfect match song/video or video/song it will sync them. When you toggle , you will be continuing the song/video where you left off. Toggle back and the same things apply. The only thing that do differ is the sound level.
  5. If google doesn't find you exact song/video it will try to pick a video/song that's is as close as possible. Sometimes it doesn't work and the app keeps the bit-rate from the video when you toggle. (Se screenshots)
Reference:
Windows 10 Desktop App
Shortcut: chrome_proxy.exe --user-data-dir="?" --profile-directory=Default --app-id=?. (Removed userdata, app-id and replaced it with a ?-sign)

Youtube/Youtube Music formats:
https://gist.github.com/AgentOak/34d47c65b1d28829bb17c24c04a0096f

Select your streaming and download audio quality:
https://support.google.com/youtubemusic/answer/9076559?hl=en

Artist
Data was harvested with a command line program, youtube-dl.exe, downloadable from Https://youtube-dl.org for verification of the "stats for nerds"
Links only works on the windows platform in Chrome.

Pentatonix
Videos/songs:
That's Christmas To Me (Deluxe Edition): Mary Did You Know
3. Perfect Match, Android 10
Code:
https://www.youtube.com/watch?v=ifCWN5pJGIE
Code:
https://music.youtube.com/watch?v=PPoEfC7T1kg
Code:
https://music.youtube.com/watch?v=ifCWN5pJGIE
Code:
youtube-dl.exe -F https://music.youtube.com/watch?v=PPoEfC7T1kg
Code:
youtube-dl.exe -F https://www.youtube.com/watch?v=PPoEfC7T1kg

Mary did you know - (Lyrics)
4. Song and Video as close as Possible
Code:
Android YTM App: https://www.youtube.com/watch?v=cZVjXsf_7aI
Code:
Android YTM App: https://music.youtube.com/watch?v=cZVjXsf_7aI
Code:
Android YTM App: youtube-dl.exe -F https://www.youtube.com/watch?v=cZVjXsf_7aI
Code:
Android YTM App: youtube-dl.exe -F https://music.youtube.com/watch?v=cZVjXsf_7aI

Toto
Videos/songs:
Live From Amsterdam, 25th Anniversary: Africa (Live)
3. Perfect Match
Code:
https://www.youtube.com/watch?v=37ZaSINRDGM
Code:
https://music.youtube.com/watch?v=37ZaSINRDGM

Toto IV: Africa
4. Song and Video as close as possible
Code:
https://www.youtube.com/watch?v=QAo_Ycocl1E
Code:
https://music.youtube.com/watch?v=37ZaSINRDGM

Special features, images
Audio_140.png
Audio_141.png
Video_244-140.png
 
Last edited:

Tks

Major Contributor
Joined
Apr 1, 2019
Messages
3,221
Likes
5,494
One thing I have to hand to Youtube, is their move to Opus. Really does invalidate nearly all other lossless formats. The filesizes are just unbelievably small and efficient.

The formatting is a bit wierd so for those a tad confused, the TL;DR is basically for the videos/music OP used:

Video (Plain old Youtube no subscription):
  1. On Desktop using Windows10/Chrome/Youbtube website: VP9

Audio (Plain old Youtube no subscription):
  1. On Desktop using Windows10/Chrome/Youbtube website: Opus Variable Bitrate at ~160kbps, 48,000 kHz

Video (Youtube Music):

  1. On Desktop using Windows10/Chrome/Youtube website: AV1
  2. On the Desktop App: AV1
Audio (Youtube Music):

  1. On Desktop using Windows10/Chrome/Youtube website: AAC Variable Bitrate at ~256kbps, 44,100 kHz
  2. On the Desktop App: AAC Variable Bitrate at ~256kbps, 44,100 kHz
  3. On Andoid: AAC Variable Bitrate at !~256kbps, 44,100 kHz
--------------------------------------------------------------------------------------------------------

In conclusion, if you're watching a video, with Premium, you get a change between VP9 and AV1 somtimes (not sure why or what the benefit currently is aside from 8K resolution support, as I assume VP9 is currently more mature, but I guess AV1 is the future, and seems to be built with the web in mind, now we just need to wait for proper hardware decoders I suppose). As for audio you basically get a jump from Opus 160kbps (which isn't bad at all, and I'm surprised you get this off plain-old Youtube videos), and MP4 128kbps, to 256kbps. Not sure if that's much of a benefit to be frank (especially over something like 160kbps Opus which should be perceptually lossless barring any anomolies) but the jump from 128kbps to 256kbps AAC is decent considering many people beam their music somewhere else, encuring a multi-compression penalty.
 

ZolaIII

Major Contributor
Joined
Jul 28, 2019
Messages
4,069
Likes
2,409
@Tks Opus uses two codecs Spex & Vobies as lo high bit rate & together in hybrid mode in the middle which 160 Kb/s is. But opus does this using a high precision math (fp 32) disassembling the original signal to multiple samples (depending on complexity) with multi release in the sampled time period that makes it both sound better and more natural while keeping the latency down. Other important thing to consider regarding Opus is the fact how it restricts bandwidth to maximum of 20 KHz meaning that all above it gets removed. All do many hire would hurry to argue how that's a good thing its rather troublesome as one's something is lost there is no way to bring it back.
In short that are characteristics of Opus that make it differ from other lossy codecs & which should be kept in mind.
 

jmaz87

Member
Joined
Jan 29, 2021
Messages
71
Likes
20
Given the above, what's the best way to consume YTM and are their trade offs if I cast to a device from android or browser.
Been using GPM for a few years, been on the fence with YTM. Music suggestion was really really bad for me initially and radio was basically broken at first.
I have recently been using Tidal with that 4month promotion. Definitely sounds different/better but how much I'm not sure. It's hard to beat the value in YT Premium.

Given that 2 of my "sources" are just TV optical out (Main source is PC in office) for gaming etc. am I gonna notice a difference casting to a gen3 chromecast vs using a laptop via hdmi?

Usually just listen to music on PC in office so those Dacs are just to accomodate headphones when i'm gaming or viewing content late.

GF uses Spotify am I better off moving to that? Its so hard to beat the value of YT Premium but Tidal hasn't "wowed" me even if it does sound a "bit" better...

any advice is welcome! ;)
 
Top Bottom