Windows 10 reached EOS (end of support) on October 14, 2025. If you are on Windows 10, see this article.

Przeszukaj pomoc

Unikaj oszustw związanych z pomocą.Nigdy nie będziemy prosić Cię o dzwonienie na numer telefonu, wysyłanie SMS-ów ani o udostępnianie danych osobowych. Zgłoś podejrzaną aktywność, korzystając z opcji „Zgłoś nadużycie”.

Więcej informacji
Wątek został zarchiwizowany. Jeśli potrzebujesz pomocy, zadaj nowe pytanie.
Rozwiązane Zarchiwizowany

How to hide tab close button

user246702795357422906659079832506949965427

Hello,

In past versions of firefox there was a config option to hide the tab close button but this got removed. I got accustomed to closing tabs with the mouse middle click so I don't need that button. It gets in the way when I try to switch tabs and I accidentally click it.

Is there a way to hide it in newer versions of firefox (56, 57)?

Thank you.

Hello, In past versions of firefox there was a config option to hide the tab close button but this got removed. I got accustomed to closing tabs with the mouse middle click so I don't need that button. It gets in the way when I try to switch tabs and I accidentally click it. Is there a way to hide it in newer versions of firefox (56, 57)? Thank you.

Wszystkie odpowiedzi (3)

Maybe you'd like to give this add-on a try - which does what the preference in 'about:config' used to do :

https://addons.mozilla.org/en-US/firefox/addon/no-close-buttons/

Wybrane rozwiązanie

You can add code to the userChrome.css file below the default @namespace line to hide the close buttons.


@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /* only needed once */

#tabbrowser-tabs .tabbrowser-tab .tab-close-button { display:none!important; }


You can use the button on the "Help -> Troubleshooting Information" (about:support) page to go to the current Firefox profile folder or use the about:profiles page.

  • create the chrome folder (lowercase) in the <xxxxxxxx>.default profile folder if this folder doesn't exist
  • use a plain text editor like Notepad to create a (new) userChrome.css file in the chrome folder (file name is case sensitive)
  • paste the code in the userChrome.css file in the editor window
  • make sure that the userChrome.css file starts with the default @namespace line
  • make sure that you select "All files" and not "Text files" when you save the file via "Save file as" in the text editor as userChrome.css.
    otherwise Windows may add a hidden .txt file extension and you end up with a not working userChrome.css.txt file

@Engima thanks for the answer, but addons that do that don't work starting with firefox 57. I'm on 57 beta and I could switch to 56 stable to use that addon but it would only postpone the problem.

@cor-el thank you, that worked. I hope Mozilla doesn't plan to remove userChrome.css any time soon.