Why is WebGL disabled in Chrome?

Security researchers identified a serious vulnerability in WebGL -which is turned on by default for Firefox and Chrome browsers. The vulnerability allows attackers to run malicious code on users’ Computers. We’ve covered how to disable WebGL in Firefox, here is how you can do that in the Google Chrome browser also.

What is WebGL?

WebGL brings hardware-accelerated 3D graphics to the browsers without the need of installing additional extensions or plugins. Most modern browsers support WebGL, as does Chrome.

A Security consultancy company Context has more details about the vulnerability in WebGL and the best way to stay secure is to by disabling WebGL in Browsers.

According to the page at Context “this vulnerability allows attackers to provide malicious code via a web browser which allows an attack on the GPU and graphics drivers. These attacks on the GPU via WebGL can render entire machines unusable.”

Google has added WebGL 2.0 support to the Chrome browser in version 56 and offered an option to disable WebGL in flags. But, that flag was taken away with version 63.

If you’re desperate to turn off WebGL in Chrome, follow the steps given below.

How to disable WebGL in Google Chrome on Windows 11/10/8/7

  1. Close the Chrome browser if it is already open
  2. Right-click on its desktop shortcut and select Properties
  3. In the Target field, after chrome.exe”, give space and add the below flag
    –disable-3d-apis.
    Why is WebGL disabled in Chrome?

  4. The Total Target field should look like when you added the above command line flag.
"C:\Program Files\Google\Chrome\Application\chrome.exe" --disable-3d-apis

When prompted for Administrator permission, click Continue. Click on ‘OK’ to save changes.

Running Chrome with the above command line switch turns off client Visible 3D APIs such as WebGL and Pepper3D,

We can confirm this will disable WebGL for Chrome as you will get a “could not initialize webGL, sorry ” error message when you launch one of Google’s WebGL, the screenshot below says the same.

 

We’ll update this post if we found more official information if any from the Chrome team or from other sources on the current issue. Stay tuned.

Final words: Do you have security concerns with WebGL in Chrome, here is how you can disable in Chrome on Windows 11, Windows 10/8.1/8, and Windows 7.

WebGL or Web Graphics Library is nothing but a JavaScript API which helps it in rendering interactive 2D and 3D graphics on any supporting web browser without any third party plugins being used. It works well along with web standards which allows it to use the GPU acceleration to render graphics and physics as a part of a web page. It greatly impacts in improving the overall performance of a web page. It is supported on a variety of web browsers like Microsoft Edge, Google Chrome, Mozilla Firefox and more. But at times, it does not work properly or is not enabled; we will learn today how to get it fixed.

Enable WebGL on Chrome & Firefox

This issue can be caused due to a number of factors. It includes both browsers as well as the operating system. The Graphics Driver also plays a crucial role in helping out WebGL to function on a computer.

Today, we will be checking out how to fix this issue on your updated browsers-

  1. Manually enable WebGL on Chrome or Firefox
  2. Update your Graphics Card Driver.

1] Manually enable WebGL on Chrome or Firefox

First of all open Google Chrome and click on the Menu button (by clicking on three dots button on the top right corner). Next click on Settings. Scroll down to find the button that is labeled as Advanced and click on it.

Under the section that goes by the name System, turn on the toggle of Use hardware acceleration when available.

Restart Google Chrome.

When it starts up again, type in chrome://gpu/ in the address bar and hit the Enter key.

WebGL is not supported

This will now display if WebGL is properly enabled or not.

Alternatively, you can open the Google Chrome browser and visit this URL: chrome://flags. Look up Disable WebGL in the search box on the top portion of the page. Toggle the appropriate entry to Disabled. Restart Google Chrome for the changes to take effect.

This will enable the touch-friendly User Experience on Google Chrome.

Firefox users can do the following. To disable Hardware Acceleration in Firefox, open the browser > Options.

disable hardware acceleration in Firefox and Chrome

Now under the General section, scroll down a bit to see Performance. Here check the Use hardware acceleration when available option.

Restart Firefox.

2] Update your Graphics Card Driver

From the WinX Menu, open Device Manager. Expand the list that says Display Adapters.

Right-click on the listing of your NVIDIA Graphics Card and select Enable. Now, right click on it again and click on Update Driver Software…

A new window will open up. On that, click on Search automatically for updated driver software.

If Windows now detects your Graphics Card and the latest driver for it, great! Else, proceed as follows:

  1. Right click on it again and click on Update Driver Software…
  2. Click on Browse my computer for driver software.
  3. Click on Let me pick from a list of device drivers on my computer.
  4. Select a compatible driver for your computer named as NVIDIA Graphic Card and proceed further.

Let the whole process finish. And then restart your PC for the changes to take effect. This will help you update your Graphics Driver.

How do I enable WebGL on Chrome?

Go to about:flags..
Press Ctrl-F or Cmd-F and search for webgl 2.0..
Find WebGL 2.0 Prototype and click enable..
restart Chrome..

How do I fix WebGL disabled?

If you are having trouble running WebGL in Firefox, please take the following steps:.
Go to about:config in your address bar..
Search for webgl. force-enabled and make sure this preference is set to true. ... .
Search for webgl. disabled and make sure this preference is set to false. ... .
Restart Firefox to apply your new settings..

How do I fix WebGL in Chrome?

Enabling WebGL on Chrome.
Start a Live Test using Google Chrome..
Scroll to Disable WebGL – Enabling this option prevents web applications from accessing the WebGL API, and then click Enable:.
Click Relaunch Now. Google Chrome will restart and your new settings will be applied..

Why did WebGL stop working?

WebGL may be unavailable due to following reasons: An extension in Google Chrome is disabling WebGL from being used. The current version of your graphics driver needs to be updated to the latest version.