20

Is there a way to listen to YouTube videos without having the video playing?

I work on a computer, and I usually listen to music while working. In the last couple of years I find myself using YouTube as almost the only source of music. However, the type of music that I like (techno, trance, house, etc) poses a problem that anyone who has ever listened to such music mixes on YouTube will understand - the videos of these mixes are basically a slideshow of a really really (really) hot babes. And while I do appreciate the pictures, it's a problem having these pics appear on the screen in the office.

As much as I try not to have this page on the screen, sometimes I need to pause the video, change it, etc.

migrated from superuser.com Feb 8 '14 at 21:39

This question came from our site for computer enthusiasts and power users.

4

Try Chrome extension: Stylebot

You can install CSS styling from lots of other users who have submitted the styling or you can just make your own.

To remove video content. You just need to use selector tool to select video element and mark height = 0.

Good thing with this extension that you can use it to style any website to remove distractions. Whenever you want to remove styling you can reset it.

See screenshot:

enter image description here

  • The style that worked for me was video { height: 1px !important; } – Fluffy Mar 8 '16 at 20:38
3

Here is a very simple userscript your can make:

var player = document.getElementById('player-api');
player.style.height = "35px";

I'll let you actually implement it.

Looks like this when done:

enter image description here

  • Thanks, this actually looks as the thing I need. However, can't really test it till I know what to do with it - I've never tried to write any script for greasemonkey or tampermonkey. Oh well, guess it's never to late to start... – kliteyn Feb 8 '14 at 22:21
  • Just tested this with Greasemonkey and it works great! Thanks! – dmikester1 Apr 24 '17 at 14:08
  • Great tip, 40px to get the scrolling – Farrukh Abdulkadyrov May 9 '17 at 17:14
1

Use Stylish for Chrome, and add the following style for YouTube URLs:

.webgl canvas, #movie_player  {
    height: 50px;
}
1

If you are using HTML5 player and playlist then the [answer with a userscript] does not work1.
I would recommend a script like this

document.getElementsByClassName('html5-video-container')[0].style.visibility='hidden';

It hides the video, but leaves the video player field. It stills loads the video in the background, but it doesn't display it.

  • 1
    Please note that "above" really has no context in answers, since they can be sorted in multiple ways, not just chronologically. It would be better to link to the answer to reference it. (Use the "share" link under the answer.) – ale Apr 7 '15 at 18:10
0

We recently added a play entrypoint to the youtube-dl-api-server . With this, after installing the webservice you can listen any youtube video by just opening urls like this:

http://example.com/play?format=m4a&url=youtube.com/watch?v=UYCilZ8yMmU

It works with any media player and you can even build playlists with these URLs!

If you want an easier client-side solution, just open the video URL in VLC, then from the "Video" menu select "Video Track->Disable".

0

There may be a method some day to do this in the browser. Right now, it's worth noting that with YouTube Red you can do this with the YouTube Music application using audio-only mode.

Use audio mode

With a YouTube Red membership, you can turn on audio mode to listen to music without loading the video. This allows you to continuously enjoy music from your favorite artists, even if you're experiencing low connectivity or video playback issues.

Until then you can either

0

invidio.us is a new platform, where you can watch and listen to youtube videos, even on a smartphone.

With the Firefox addon hooktube, you can automate a redirect for all youtube videos

-1

First:
Youtube doesn't seem to want any audio-only listeners:

Google alluded to the fact that the terms of service do not allow separate playback of audio and video, or advertisements to be blocked

Source: https://thenextweb.com/insider/2015/07/21/how-youtube-killed-an-extension-with-300000-users/

Second:
All working solutions here only hide the video from the eye (which can be easily done by just switching to another tab or window) so the whole data for the video is still be downloaded and the video-part is wasted bandwidth.

So I would suggest this solution:

Do not use YouTube to "listen" to videos

There are lots of free alternatives to Youtube that only stream audio and additionally allow to listen to and organize your favorite music and also have a much better continuous music control flow than youtube (for example, you can continue to listen the current song while searching the next one)

here is a good overview of free streaming sites

This might not always be a solution, but I think this answer has to be added for a complete list of possibilities.

  • +1 Agreed the reason of this answer. Nonetheless some streaming sites listed are down and some call for YouTube videos. – Shirley Temple May 30 '17 at 3:19
  • 1
    +1 for the link to the Youtube TOS. As for the rest - I know that there are good streaming sites (many are unavailable outside US), but I was asking about Youtube specifically. – kliteyn Jul 3 '17 at 14:17
  • This is clearly not true as the Phone Application can do it with YouTube Red. – Evan Carroll Apr 18 '18 at 19:56

Not the answer you're looking for? Browse other questions tagged or ask your own question.