Google making YouTube slower for non-Chromium browsers? - gHacks Tech News


If you use Microsoft Edge or Mozilla Firefox to access YouTube to stream videos, read comments, or interact with the site in other ways, you may have noticed that the site is slow as molasses. If you perform the same operations in Chrome or other Chromium-based browsers, performance is blazing fast instead.

A Twitter message by Mozilla's Technical Program Manager Chris Peterson has created heated discussions on Twitter, Reddit, and elsewhere about YouTube's use of a deprecated API that favors Chrome and other Chromium-based browsers over competing browsers such as Microsoft Edge and Firefox.

Peterson stated the following on Twitter:

YouTube page load is 5x slower in Firefox and Edge than in Chrome because YouTube's Polymer redesign relies on the deprecated Shadow DOM v0 API only implemented in Chrome.

YouTube serves a Shadow DOM polyfill to Firefox and Edge that is, unsurprisingly, slower than Chrome's native implementation. On my laptop, initial page load takes 5 seconds with the polyfill vs 1 without. Subsequent page navigation perf is comparable.

YouTube launched a design refresh last year, and one of the changes that Google implemented on the video streaming site was to make use of a deprecated API that only Chrome supported. Use of the API improved YouTube on browsers that support it and made the performance of browsers not supporting the API noticeably worse.

Peterson went on to state that YouTube serves Internet Explorer 11 users with the classic site which does not impact performance, and that Google should have done the same for Firefox, Edge and other affected browsers.

He mentioned a userscript and Firefox add-on that Edge and Firefox users could install to restore access to the classic version of YouTube. Doing so restores the old site and improves performance significantly when these browsers are used to access YouTube.

A thread on Reddit suggests another option that involves using the Developer Tools and modifying a cookie that YouTube set.

Microsoft Edge

youtube classic edge

  1. Visit the YouTube website in the Edge web browser.
  2. Use Menu  > Developer Tools or press F12 to open the browser's developer tools.
  3. Select Debugger > Cookies > www.youtube.com. If you don't see Debugger, locate Application instead and activate it.
  4. Find the Pref row.
  5. Double-click on value and paste al=en&f5=30030&f6=8 into the field.
  6. Reload the YouTube page.

Mozilla Firefox

youtube faster firefox

  1. Visit YouTube in the Firefox web browser.
  2. Press Shift-F9 to open the Storage Inspector.
  3. Locate https://www.youtube.com/ under cookies and select it.
  4. Locate the Pref cookie.
  5. Change its value to al=en&f5=30030&f6=8
  6. Reload the Youtube page.

Note that since the method is cookie based, it needs to be done again whenever the cookie is deleted. You may also watch YouTube on the desktop to avoid all these issues.

Closing Words

It is pretty clear that YouTube's engineers knew what they were doing when they implemented support for the API. Research of compatibility issues would have pointed them to issues with the implementation in Edge or Firefox. The engineers could have decided to serve the old site to users of Firefox or Edge similar to serving the classic site to Internet Explorer 11 users but they decided against it.

Now You: What is your experience on YouTube?

Summary

Google making YouTube slower for non-Chromium browsers?
Advertisement