The (Almost) Ultimate YouTube Viewing Experience

Recently, there have been a fair few people decrying how much worse the YouTube UI has become recently. Rebuffering when skipping backwards, quality changes which don’t take, only partially buffering videos during pause, and good old slowly downloading videos.

Would you believe me if I said that I could solve all your problems? Well, I can’t. Sorry.

I can make it all a lot better, however. To do this, you need a browser capable of running Userscripts. Firefox has best results, but Chrome works too.

We’ll be using a tragically-unknown userscript called Viewtube. Viewtube replaces the native flash players of a number of video websites, and replaces it with the player of your choice – including your browser-native HTML5 player!

  1. On Firefox? Make sure you have Greasemonkey! Scriptish works too, but has been badly maintained for a while, your mileage may vary.
  2. On Chrome? Grab Tampermonkey! https://chrome.google.com/webstore/detail/tampermonkey/dhdgffkkebhmkfjojejmpbldmpobfkfo?hl=en
  3. Now grab ViewTube. It’s a userscript! https://userscripts.org/scripts/show/87011 Click that big button what says Install!
  4. OPTIONAL: Like porn? Of course you do, here’s an addon to give ViewTube support to porn sites. http://userscripts.org/scripts/show/159658
  5. Visit youtube.com/html5 and make sure that you are *not* enrolled in the test!
  6. Now jump on down to your favourite YouTube video. Here it is: http://www.youtube.com/watch?v=vTuOBXZ3upA
  7. You should see this: Viewtube Options
  8. The first dropdown is the current video quality/format selector.
  9. From the second dropdown list, select HTML5. This determines which player is used.
  10. Click “autoplay” to toggle it on. This ‘creates’ the <video> element upon page load. Browser options determine whether the video actually autoplays.
  11. The next button to the right of autoplay is the default quality selector. If you want best resolution video by default, click this button till it displays “UHD”. Otherwise, click it till you see the resolution you want.
  12. WebM or MP4 shouldn’t matter. Change if you have issues, but both Firefox and Chrome support both.
  13. The last two buttons change layout. Be brave and click!
  14. FIREFOX ONLY! To enable “autobuffer but not autoplay”, open a new tab, browse to about:config, promise mummyfirefox that you’ll be careful, search for autoplay, and doubleclick “media.autoplay.enabled” to set it to *false*. If viewtube’s autoplay is on, you now have autobuffer-but-not-autoplay mode on!

This will replace the shitty youtube player with a nice, simple native one. It will autobuffer on page load, but never autoplay. It will buffer the entire video and never discard it. Well, not until the tab is unloaded or refreshed.

Youtube does some funny JS-based page changes when you click on videos (say, from related video lists) when on a video page already. Basically just loads the new page using AJAX and replaces it in-place. Apprantly this speeds things up. Also breaks viewtube. If you’re stuck with the default player, refresh. Opening videos in new tabs avoids this issue. I’d love some help with disabling this behaviour!

Viewtube configuration is website-specific, so you will have to click buttons to configure viewtube again for it to work correctly on other sites.

I don’t know of a way to get Chrome to not autoplay html5 videos. You can use Viewtube’s autoplay, or accept having to click the video to start playing AND buffering. Your fault for using chrome. Also, the chrome html5 player is pretty crap, lacks double-click to full screen and click-video-to-play.

Videos will have no ads, but also no subtitles or annotations. For the tiny minority of videos which use such features in a non-obnoxious way, just turn off the script and refresh. Also breaks DRM’d videos like music videos. Sorry, folks who use youtube as a music player.

Enjoy. I love comments, so post away. I’m especially looking for help fixing the Chrome autoplay issue, and the YouTube ajax page load thing.

6 thoughts on “The (Almost) Ultimate YouTube Viewing Experience

  1. It would be really great if this script also supported the “hover over video timeline to get a preview thumbnail” but I suspect this feature is only possible with the native Youtube player

    • Yeah, unfortunately I’m pretty sure that feature is done on the server-side. Google’s servers extract a set of thumbnails from the video and send them on page load.

      This setup does cause you to make sacrifices, but at least the video plays well – and you can turn the script off easily.

  2. Doesn’t work for me on Chrome using Tampermonkey. No options bar appears, no errors in the console. Thanks anyway.

    • That’s odd. I’ve tested this and it works fine. I have little chrome experience, being a firefox user, but you could try checking that chrome is updating itself and its addons correctly, and try wiping your profile and starting from scratch.

  3. To disable autoplay on html5 videos on chrome you need to remove “obj.autoplay = ‘autoplay’;” (without quotes) from ViewTube’s userscript.
    You can find it around here:

    // ==========Functions========== //

    function createMyElement (type, content, event, action, target) {
    var obj = page.doc.createElement(type);
    if (content) {
    if (type == ‘div’) obj.innerHTML = content;
    else if (type == ‘img’) obj.src = content;
    else if (type == ‘option’) {
    obj.value = content;
    obj.innerHTML = content;
    }
    else if (type == ‘video’) {
    obj.src = content;
    obj.controls = ‘controls’;
    obj.autoplay = ‘autoplay’; <———————-Remove this line
    obj.volume = 1;

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s