This works by overwriting YouTube's CSS using Firefox's userContent.css
file.
- Open Firefox.
- Type
about:config
into the address bar and press Enter. - Click Accept the Risk and Continue if prompted.
- In the search bar, type
toolkit.legacyUserProfileCustomizations.stylesheets
. - Set the preference to
true
by double-clicking it.
- Type
about:support
into the address bar and press Enter. - In the Application Basics section, locate Profile Directory.
- Click the Open Directory button next to Profile Directory.
- In your profile directory, create the
chrome
directory if it doesn't exist. - Place the following into the
chrome
directory:
userContent.css
youtube.css
themes
- Open
userContent.css
in a text editor. - At the top, you'll see this import:
@import url(./themes/tokyonight-night.css);
- Edit the import URL to your desired theme.
- For example:
@import url(./themes/catppuccin-mocha.css);
Close and reopen Firefox for the changes to take effect.