[SOLVED] How can I hide streams from my YouTube subscriptions page?

hungariantoast
Thu, 23 Jan 2025 18:23:06 +0000

Picture explanation:

https://i.horizon.pics/tWovRax4kh.jpg

When I view my subscriptions page on YouTube, half the "videos" are recordings of completed streams, often 2+ hours in length. I'm not interested in watching these. For me, they're just pollution in the feed.

Apparently, a lot of the channels I subscribe to, whose videos I enjoy watching, also stream on YouTube a lot.

Second Wind is probably the channel I'm most hung up about. I like their normal videos, and don't want to unsubscribe from their channel, but jesus they stream two or three times a day.

(Also, it's annoying that when I view a YouTube channel, I can visit their videos page or their streams page separately. Why can't I have this same separation on my own subscriptions page?)

(Also also, I already use an extension to hide shorts (among other things), but it unfortunately does not have a feature for hiding streams.)

Fancy bullet point summary:

I want to hide recorded streams from my subscriptions page

I don't care as much about hiding active livestreams, because those don't pollute my subscriptions page nearly as much

I do not want to unsubscribe from any of the channels I follow. That is not an option

I'm willing to stop using youtube.com in favor of an alternative client (web, desktop, etc) if that client supports hiding recorded streams from actual videos

I'm willing to install a browser extension that can solve this problem (but I can't find one for Firefox)

Ninja edit:

While writing up this topic, I actually found my own solution. The browser extension I mentioned earlier has an "advanced blocking" feature that takes a JavaScript function as input. The extension's GitHub page has an issue, with a comment, with some code to hide streamed videos on the subscriptions page.

However, that code didn't work when I tried it. Thankfully, I just needed to check for videoRenderer instead of gridVideoRenderer.

Here's the updated code:

(video, objectType) => {
    // Only videos on the Subscription page
    if ( objectType === "videoRenderer" ) {
        if ( video.hasOwnProperty("badges") && video.badges.includes("live") ) {
	    return true;
        }
        if ( video.hasOwnProperty("publishTimeText") && video.publishTimeText.indexOf("Streamed") != -1 ) {
            return true;
        }
    }
    return false;
}

I have no idea what the consequences of checking against videoRenderer instead of gridVideoRenderer might be, and right now I'm too lazy to find out. This works well enough for now.

(The "consequence" might be that streams are hidden from the related/recommended videos in the sidebar of a video page? I actually hide that sidebar, so I wouldn't know. Oh, and they'll probably be hidden from a channel's streams feed.)

It isn't a perfect solution though. Streams that are "scheduled" still show up on the subscriptions page. However, I think channels can set streams and videos as scheduled? So blocking one without the other would be more complicated?

I welcome any feedback or improvements on the code.

Comments URL: https://tildes.net/~tech/1lig/solved_how_can_i_hide_streams_from_my_youtube_subscriptions_page

Votes: 15

Comments: 8