How to enable YouTube HTML5 video support in Mozilla Firefox

While Mozilla Firefox has good support for HTML5 standards, you might have noticed that it does not support all features required to play videos on YouTube without having Adobe Flash Player installed. It supports the required HTMLVideoElement, but some videos do not play anyway. Those videos require the Media Source Extensions feature which is disabled by default in Firefox. By default, this option is off in Firefox, so the browser is not able to play some HTML5 video streams. If you prefer HTML5 videos over the Adobe Flash Player, you might want to enable Media Source Extensions to get advanced support of HTML5 videos in Firefox.

  1. Open the Firefox browser and type the following in the address bar:

    Note: A warning page may appear that says "This might void your warranty!". Click "I'll be careful, I promise!" to continue to the about:config page.
    careful promise

  2. Type the word: "mediasource" (without quotes) in the filter text box.
  3. You will see the media.mediasource.enabled parameter which is set to false. Double click it to change its value to true.
  4. Restart Firefox.

Now open some HTML5 video from YouTube that did not play initially. Now it should play without any issues.

11 thoughts on “How to enable YouTube HTML5 video support in Mozilla Firefox

  1. zydrius32

    This option makes the watching of the videos very unstable, at least for me it‘s better to just leave the Firefox like it was before.

    1. Sergey Tkachenko Post author

      Then you need Flash Player.

  2. Maseo

    you have to add something else to have MSE & H.264 working
    see ->

    1. Sergey Tkachenko Post author

      Well, I covered that recently too

  3. Ronald Geiken

    I applied the fix mentioned in this article and it allowed me to view You Tube Videos again. I had to watch a video in Chrome earlier, but I have Firefox as my normal browser so something like that from Mozilla is enough to send a lot of people moving over the another browser in a hurry. Firefox does a lot of annoying things, but this was one of the worst. If it wasn’t for sites like this, you might have a problem getting things working right for you.

  4. Balogun

    Hey Sergey,
    How can I get Firefox (41.0 , Linux) to default to Html5 ? I don’t remember having to visit every time I restarted Firefox. Another thing I noticed was embedded youtube videos use Flash even after setting my default player to use Html5. Only thing my browser doesn’t support according to youtube’s Html5 page is ‘MSE & WebM VP9’

    Thanks In advance.

    1. Sergey Tkachenko Post author

      Please consider to update your browser to version 42.
      They unlocked MSE out of the box.
      It should handle such things better.
      Also, install these packages:
      gst-plugins-base 1.6.1-1 [installed]
      gst-plugins-base-libs 1.6.1-1 [installed]
      gstreamer 1.6.1-1 [installed]
      gstreamer0.10 0.10.36-4 [installed]
      gstreamer0.10-bad 0.10.23-10 [installed]
      gstreamer0.10-bad-plugins 0.10.23-10 (gstreamer0.10-plugins) [installed]
      gstreamer0.10-base 0.10.36-3 [installed]
      gstreamer0.10-base-plugins 0.10.36-3 (gstreamer0.10-plugins) [installed]
      gstreamer0.10-ffmpeg 0.10.13-2 (gstreamer0.10-plugins) [installed]
      gstreamer0.10-good 0.10.31-9 [installed]
      gstreamer0.10-good-plugins 0.10.31-9 (gstreamer0.10-plugins) [installed]
      gstreamer0.10-ugly 0.10.19-15 [installed]
      gstreamer0.10-ugly-plugins 0.10.19-15 (gstreamer0.10-plugins) [installed]

      Your versions might be different, but you got the idea about package names.

      1. Balogun

        Both problems persist after upgraded firefox (42). I have the gstreamer packages (don’t know how), except for gst-plugins packages I couldn’t install or find for Fedora (22). The upgrade did fix my MASSIVE audio problems on soundcloud though so thanks.

        I disabled flash and it solved both problems but it’s not ideal. Added some screenshots to better illustrate my problems. html5 works better with my extension.

  5. Randy

    My Firefox would tell me my browser wouldn’t play the videos. I’d click anyway, some box came up in the upper left corner, I clicked on “allow” and then it played. Now, no box; no play. The link to the “” Doesn’t have any place to enable html5 to play. I don’t know what to do and your solution with mediaresources does nothing at all. Thanks

  6. fixdoesnot work

    doesn’t work, dude!

  7. แหล่งท่องเที่ยวเชียงใหม่

    Thanks In advance.


Leave a Reply

Your email address will not be published. Required fields are marked *