Enable Wayland Support for Firefox/Chrome in Ubuntu 22.04 for Better Experience

Last updated: December 20, 2023 — 3 Comments

Running Ubuntu 22.04 with the default Wayland session? You can switch your web browser’s backend to get even faster and smoother experience.

Firefox, Google Chrome and Chromium based web browsers do have native Wayland support, but they still use X11 as backend in Ubuntu desktop.

Since Ubuntu 22.04 by default logs into Wayland session, user can also change the web browser’s backend to get faster and smoother browsing experiences. I didn’t run any benchmark. But after switching to Wayland, my browser now has:

  • obviously better touchpad scrolling
  • 2-finger spread/pinch gestures to zoom in/out

Enable Wayland for Chrome/Chromium

For Google Chrome, Chromium and their based web browsers, e.g., Edge, Vivaldi, just type chrome://flags/ in address bar and hit Enter.

When the page opens, search for Preferred Ozone platform and use the dropdown menu to set it value to “Wayland“. Finally, click “Relaunch” button to apply change by restarting the web browser.

Chrome enable wayland

Native Wayland for Firefox

Since Firefox 121.0, it uses Wayland by default if available, but NOT for pre-installed Firefox Snap package in my case.

To enable it for Snap package, either open terminal and start Firefox with Wayland from terminal:

env MOZ_ENABLE_WAYLAND=1 /snap/bin/firefox

Or, open “Files” (Nautilus file browser), press Ctrl+H then find out and edit the .profile file.

When the file opens in text editor, add the line below in the end and save it.

export MOZ_ENABLE_WAYLAND=1

To apply the change, you need to log out and back in.

Twitter

I'm a freelance blogger who started using Ubuntu in 2007 and wishes to share my experiences and some useful tips with Ubuntu beginners and lovers. Please comment to let me know if the tutorial is outdated! And, notify me if you find any typo/grammar/language mistakes. English is not my native language. Contact me via ubuntuhandbook1@gmail.com Buy me a coffee: https://ko-fi.com/ubuntuhandbook1 |

3 responses to Enable Wayland Support for Firefox/Chrome in Ubuntu 22.04 for Better Experience

  1. Thank you for the article

  2. Can you please, make guide on – How to create a own web browser using Chromium source in Ubuntu.

  3. this one helped me out. i had an issue where the ctrl+s menu would become unclosable, but doing this fixed it.

Leave a Reply

Text formatting is available via select HTML.

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> 

*