You are here

Firefox to convert old YouTube Flash code to HTML5 Video

Mozilla has added a feature to Firefox 46 that will convert old YouTube Flash code to HTML5 Video automatically under certain circumstances.

When YouTube started out, Flash was the dominating technology used to stream video on the Internet, and the first player that YouTube made available to webmasters to embed videos on third-party sites used Flash exclusively.

YouTube changed the code later on to reflect changes in streaming technologies. From a technical perspective, YouTube started to offer embed codes as iframes instead of objects.

The Flash code works fine after all these years, but only if Adobe Flash is installed in the browser. If that is not the case, a "plugin is missing" error message is displayed.

If you take this old Ghacks article on Line Rider, and there specifically the first video embedded on the page, you will get the error message "A plugin is needed to display this content" if Flash is not installed in the browser or blocked on the site.

firefox flash embed

The second video on the same page uses the new embed code and it won't show the error message as the HTML5 video player is used in this case automatically.

Since Mozilla does not have the luxury of a native Flash integration and the fact that plugins will be a thing of the past in the near future, something had to be done about that.

Mozilla added code to its Firefox web browser to convert embedded YouTube videos using the old Flash embed code to the new embed code if Flash is not installed or enabled on the page. This affects YouTube embeds on third-party sites only.

It needs to be noted that Firefox won't enforce the use of HTML5. If Flash is installed in the browser, nothing changes at all as Flash will be used in the case to power the video player.

Deactivate the feature

Mozilla plans to launch the feature in Firefox 46. It is already part of the organization's Nightly web browser and enabled by default.

firefox youtube embed

Firefox users who don't require the feature, can deactivate it in the following way:

  1. Load about:config in the browser's address bar.
  2. Confirm that you will be careful if a warning prompt is displayed.
  3. Find plugins.rewrite_youtube_embeds using search.
  4. Double-click on the preference name.

If you set it to false, Firefox will not rewrite old Flash YouTube embed code if Flash is not installed or enabled.

You may change the preference to its default value at any time by repeating the process outlined above.

Closing Words

While I don't encounter many old YouTube videos embedded on third-party websites, it seems to have been something of a problem for part of Mozilla Firefox's user base.

The way it is implemented offers the best of both worlds as users who don't want the feature can disable it easily in the browser's advanced configuration dialog. 


This article was first seen on ComTek's "TekBits" Technology News


Theme by Danetsoft and Danang Probo Sayekti inspired by Maksimer