Advertisement

How to run Firefox in private browsing mode from the command line or a shortcut

Private browsing mode is a feature of the Firefox browser designed to not record the history of your web surfing. When you open a new private window, Firefox does not retain cookies, temporary internet files, history, and other data related to your browsing activities. When the Private browsing session window is closed, this data is cleared. Additionally, Firefox will reset the clipboard content for better privacy. Private Browsing mode can be activated in settings, there you can enable it permanently so Firefox always runs in private mode. However, you might want to run it usually in normal mode and only have a shortcut instead to run Firefox in private mode.

To do this, Mozilla Firefox supports a special command line switch, -private-window, which tells the browser to start the private browsing session.
The command line must be like this:

firefox -private-window

Note the hyphens before 'private' and 'window'. You can type the above command directly in the Run dialog (press Win + R shortcut keys on the keyboard and press Enter after typing it).
firefox private switch
It will work even if you don't enter the full path to firefox.exe because Firefox adds a special run alias to run the browser directly.
firefox private window
You can create a shortcut to this command and also assign a global hotkey for this shortcut to open the Private Browsing mode directly, as described in this article: Add global hotkeys to launch your favorite applications in Windows 8.1.

Support us

Winaero greatly relies on your support. You can help the site keep bringing you interesting and useful content and software by using these options:

If you like this article, please share it using the buttons below. It won't take a lot from you, but it will help us grow. Thanks for your support!

Advertisеment

Author: Sergey Tkachenko

Sergey Tkachenko is a software developer who started Winaero back in 2011. On this blog, Sergey is writing about everything connected to Microsoft, Windows and popular software. Follow him on Telegram, Twitter, and YouTube.

2 thoughts on “How to run Firefox in private browsing mode from the command line or a shortcut”

Leave a Reply

Your email address will not be published.

css.php
Using Telegram? Subscribe to the blog channel!
Hello. Add your message here.