Don’t leave a trace: Private Browsing in Firefox

Today, a major feature was added to the pre-release versions of Firefox 3.1, called Private Browsing.  I’ve been working for quite some time on this, so I thought it may be a good time to write about what this feature is and how to use it.

As you may know, while you browse the web, your browser usually records a lot of data which will later be used to improve your browsing experience.  For example, it records a history of all the web pages you have visited, so that later if you need help remembering a site you visited a while back, it can assist you in finding that site.  Now, that is great, but there is a downside: those data can be used to trace your online activities.  For example, if your coworker sits at your computer, she can view all of your browsing history, which may not be what you want.

Suppose you’re doing something online, and you don’t want your coworkers know about it.  An example scenario would be looking for a new employer while at work!  One option would be to do your work, and then clear the data that Firefox has stored for you, such as history, cookies, cache, ….  But the problem is that this action will also remove the parts of your online activities data which you don’t want to hide, so the history that Firefox records can no longer be used to find a web site you had visited a month before.  Private Browsing will help you here.

Private Browsing aims to help you make sure that your web browsing activities don’t leave any trace on your own computer.  It is very important to note that Private Browsing is not a tool to keep you anonymous from websites or your ISP, or for example protect you from all kinds of spyware applications which use sophisticated techniques to intercept your online traffic.  Private Browsing is only about making sure that Firefox doesn’t store any data which can be used to trace your online activities, no more, no less.

So how does one actually use this feature?  It couldn’t be simpler!  To start, just select Private Browsing from the Tools menu.

To start, just select Private Browsing from the Tools menu.

You will see a dialog box which asks you whether you want to save and close all of your current windows and tabs, and start the Private Browsing mode.  Click Start Private Browsing to start your private session.

Click Start Private Browsing to start your private session.

After you do this, your non-private browsing session is closed and a new private session is opened, showing you the screen below.  (Before you mention, the ugly icon you see there is something I created as a placeholder!  This icon will be replaced in the final release of Firefox 3.1.)

Start of the Private Browsing mode

As you see, not much is different in the Firefox window inside the Private Browsing mode, except for the (Private Browsing) text added to the title bar at the top of the window.  That is intentional: after all, if you’re doing something online that you don’t want your coworkers to know about, you don’t want to raise their attention with a big sign saying PRIVATE as they pass by and glance over your shoulder. 

At this stage, you can start browsing web sites, without ever having to worry that Firefox might store something on your computer which can be used to tell which pages you have visited.  Once you’re done, just uncheck the same menu item in the Tools menu to close your private session.

Once you're done, just uncheck the same menu item in the Tools menu to close your private session.

 This action discards all of the data from your private session, and will restore your non-private browsing session, just like it was before entering the Private Browsing mode.

This action will restore your non-private browsing session, just like it was before entering the Private Browsing mode.

Now, as I mentioned at the top of this post, this feature is available in pre-release versions of Firefox 3.1 (what we geeks call nightly builds).  This feature will be included in Firefox 3.1 Beta 2 which will be released soon, so if you want to try it, you can give it a shot then.  And of course, it will appear in the final release of Firefox 3.1, so if you’re not the type who test beta software, you can wait until Firefox 3.1 is released.

Update:  As many people seem interested in knowing this, there is a way to make Firefox always start in Private Browsing mode.  Go to the about:config page, click I’ll be careful, I promise, type browser.privatebrowsing.autostart in the Filter text box, double click the entry to make its value true.  After doing this, the next time you start Firefox, it will start in private browsing mode automatically.  To turn this off, use the same steps to change the value of this preference to false.  There is a plan to provide an easier method to set this option in the final release of Firefox 3.1.

Posted in Blog Tagged with: , , ,
319 comments on “Don’t leave a trace: Private Browsing in Firefox
  1. Michael says:

    Nice to see yet another write up of private browsing that doesn’t mention it’s usefulness at hiding browsing of porn! I imagine this feature will get a lot of coverage – I wonder if any of it will actually mention porn. (Of course I realise that there are other real uses for the feature, and porn isn’t something that everyone wants to discuss or be associated with – and that of course is why this privacy feature is useful for it…)

    Anyway, good work on getting it done – it’s obviously not easy implementing a feature which touches so many parts of the code.

  2. Aaron Train says:

    Congrats Ehsan!

    All the hard work paid off, good to see the work done!

    – Aaron T

  3. Dave says:

    “Suppose you’re doing something online, and you don’t want your coworkers know about it. An example scenario would be looking for a new employer while at work! ”

    Every company with more than a few hundred employees will probably have some sort of internet monitoring installed. So you aren’t defeating anyone by entering private mode.

  4. crf says:

    What about flash cookies? Does it handle them as well?

  5. Wayne Alligood says:

    Very good work. This is certainly something I’ve been waiting for. Keep up the good work.

  6. Ehsan Akhgari says:

    Thanks!  Yes, porn might be a very compelling example here.  Mozilla already includes such features, such as libpr0n

  7. Ehsan Akhgari says:

    Thank you for helping out in writing some unit tests for the feature — great job!

  8. Ehsan Akhgari says:

    Yes.  But like I mentioned in the post, Private Browsing only ensures that Firefox doesn’t store any data which can tie your browsing activities to a specific site.  So, as long as the only employees you want to protect from are the ones who sit at your computer and browse through your history and stuff, you should be fine with Private Browsing mode.

  9. Ehsan Akhgari says:

    No, we don’t currently handle them, and I don’t expect this to ever happen in Mozilla core.  But this is also something which extension authors might look into as well.

  10. Ehsan Akhgari says:

    Glad to hear it.  Your feedback is highly appreciated, so please don’t hesitate to let me know if you have any suggestions/criticisms.

  11. skierpage says:

    Thanks for the feature, I just tried it in Firefox 3.1 nightly and it worked fine. Here’s another way to get similar private browing that I think works in Firefox 2 and 3.

    I have a profile in Firefox named “testing” with Tools > Options > Privacy > “Always clear my private data when I close Firefox” checked and set to throw away everything.

    If I start Firefox with the command-line options “-no-remote -P” , I can run a second instance of Firefox along with my regular instance; it prompts for a profile. That second instance doesn’t save anything.

    I use this to reproduce Firefox bugs in a bare-bones profile with no add-ons or history while entering bug reports in my regular profile; but it’s also useful for private browsing and I can keep my 12 regular tabs and multiple windows going.

  12. Ehsan Akhgari says:

    Thanks for sharing this solution.  Please note though that this is not really equivalent to what Private Browsing provides.  Private Browsing ensures no such data ever gets written to disk, so for example if your browser crashes along the way, nothing will be left on disk.  Also, with Private Browsing, what you get is really a version of Firefox with all of your customizations (extensions, themes, settings, bookmarks, etc.), not a brand new profile which you need to customize from scratch to match your specific taste.

  13. skierpage says:

    I have Tools > Options > Privacy > Cookies set to “Ask every time”, and when I first visit a site and get the “Confirm setting cookie” dialog I either allow session cookies or deny cookies (and, rarely, allow permanent cookies) and remember the decision for each site. It’s a hassle but lets me blacklist some sites and deny permanent cookies to most.

    When I switch to private browsing, sites still ask me if I can set the cookie, but I can’t check “Use my choice for all cookies from this site” because the checkbox is disabled So I keep getting the “Confirm setting cookie” dialog over and over.

    I assume the handling of cookies in Private Browsing is “Allow for session”. I would document that this is the setting in Private Browsing, that it can’t be changed, and that “Ask every time” can’t be set, and then never show the dialog in Private Browsing mode, regardless of the user’s privacy settings. OR, you could try to create some hella complex options for private browsing…

  14. leandro says:

    I’m sure you had a lot of hard work, but I want to say thank you!
    This feature is really awesome, i’ve been waiting for something like this for ages… And it open a lot of interesting ways that the addons’ developers can follow.

    Congrats and thank you again, Ehsan

  15. Ehsan Akhgari says:

    Thanks for your feedback!  I think your suggestion of never showing this dialog might have some merits.  I posted your comments on the relevant bug in Bugzilla, so we will consider it, and it may happen for the final release of Firefox 3.1 if others share my opinion as well.

  16. If am conducting a job search at work and can’t finish what I’m doing and have to revert back to my job duties (rats!) I will lose all those cool jobs I found posted on different sites. How about storing encrypted bookmarks that are automatically unlocked in private mode? That way I (and everyone else looking for a job) can be much more efficient in private mode.

    Pleeeeeeeeeeeeeeeez!

  17. […] also released news of their new “private browsing” features. Firefox’s new feature attempts to make sure that your web browsing activities […]

  18. Thanks and congratulation – really nice work. However, there is something in the UI that doesn’t behave the way I would expect it. Private Browsing opens a new window, you can actually see the old window being closed and the new window open up. So I would expect that closing that new window will switch off Private Browsing again. Instead, the browser exits and my old session isn’t even restored when I start it again.

  19. JinHu says:

    I would rather prefer a mix between the private mode, but in each tab like cookiepie.

    Thanks!

  20. Paul says:

    If you use Indeed.com to search for jobs, you can save any jobs in your my.indeed account. So, you can stay in Private Browsing mode and come back to Indeed.com at any time to find your saved jobs. No need for encrypted bookmarks!

  21. Ehsan Akhgari says:

    Such a feature, like this one, needs major architectural changes.  This may happen in a future release, but there simply isn’t enough time to include this in Firefox 3.1.

  22. Ehsan Akhgari says:

    Thanks a lot for your feedback.  Actually, the original UI plan was to restore the non-private session as soon as the last window in Private Browsing mode is closed.  But we thought that it would be awkward, because then the close button would have two different semantics based on the state of the browser.  But your suggestion of restoring the old session if exiting inside the Private Browsing mode is certainly worth considering, so I mentioned it here.  This may also be included in the final release of Firefox 3.1, hopefully.

  23. Ehsan Akhgari says:

    This doesn’t fall into the scope of Firefox per se, but it would be an area where an extension can help…

  24. Visitor says:

    If you’re going to show text indicating what is and what is not stored, be sure to mention that Flash cookies will continue to be stored.

  25. […] 3.1 intègrera un mode privé permettant de surfer sans laisser de traces sur son ordinateur ce qui ne veut pas dire que vous […]

  26. […] 3.1 intègrera un mode privé permettant de surfer sans laisser de traces sur son ordinateur ce qui ne veut pas dire que vous […]

  27. Pete Austin says:

    Any chance of making this property link-specific?

    I’d prefer the situation where clicking a desktop link that was saved from private mode launches Firefox in private mode, and clicking other links doesn’t.

    That way I could automatically use private mode for most Web use, but get the benefit of browser history with sites that I visit while doing research, such as Techmeme.

  28. […] So are you excited to see private surfing added to Firefox or is this one of those “ehh, I guess it is ok” features for you too? Learn more about it at ehsanakhgari.org.  […]

  29. […] 3.1 intègrera un mode privé permettant de surfer sans laisser de traces sur son ordinateur ce qui ne veut pas dire que vous […]

  30. […] if you’re feeling adventurous, you can try the latest Firefox 3.1 build which finally has this feature. It’s simple – although not as elegant as in Chrome, which […]

  31. […] if you’re feeling adventurous, you can try the latest Firefox 3.1 build which finally has this feature. It’s simple – although not as elegant as in Chrome, which […]

  32. […] Read the Entire Story…Source: Ehsanakhgari […]

  33. […] Akhgari has more information available about private browsing, and thankfully he’s put forth a possible application that doesn’t directly involve […]

    • Nice feature! Question is, will it have a quick shortcut using ctrl+(something) or alt+(something) so the previous session can be quickly recovered. Like you said, if you were applying for a job and someone is walking over could you go back to ‘work’ without lots of mouse movement and clicking?

      Great idea though!

      • […] dem Weblog vom Firefox-Entwickler Ehsan Akhgari ist die Info zu finden, das die Funktion für das […]

        • Asher says:

          I find the “Start Private Browsing” dialog confusing. especially, what does “Cancel” do ?
          I wish this mode could be set on a per tab basis. Of course, opening a new tab from an existing “private” tab would make the new one “private” as well.
          I agree the visual indication should be as discrete as possible.
          Also, why is “Work offline” still in the File menu ? Shouldn’t it also be under Tools ?

        • Ehsan Akhgari says:

          Cancel aborts the mode switch of the browser.  In other words, if you press Cancel, you will stay in the non-private mode.

          As I have described in many previous comments, our current architecture does not allow us to easily have a per-tab private browsing implementation.

          Regarding the Work Offline menu, I’m really not sure. 

    • Ehsan Akhgari says:

      Currently, pressing Alt+T and B successively achieves this effect.  (Alt+T opens the Tools menu, and B toggles the Private Browsing menu item, turning the mode off.)

  34. […] seinem Blog beschreibt der Firefox-Entwickler Ehsan Akhgari das zukünftige Feature, welches inzwischen spöttisch als […]

  35. […] seinem Blog beschreibt der Firefox-Entwickler Ehsan Akhgari das zukünftige Feature, welches inzwischen spöttisch als […]

  36. Ehsan Akhgari says:

    Not all users have Flash installed.  Others might have it installed but disabled it.  And the same goes for any other plugin besides Flash which might store data about your browsing history…

  37. Ehsan Akhgari says:

    I agree that this would be a useful feature to support, but as I mentioned in response to previous comments, this would require major architecture changes in the Mozilla code base, which may or may not happen in a future release.

    • […] There are several new features, but the one that most users will be using is the new private browsing available. Basically, this is mode that will allow you to serf the web as normal, but when you are done, you can erase ALL evidence of your activities.  The example situation given would be searching for a new job while at your current empoyer. Check out more about private browsing. […]

  38. Estetik says:

    of the cool new features of the upcoming Firefox 3.1 is Private Browsing. Essentially, when you enable Private Browsing, nothing of what you do in Firefox is recorded

1 Pings/Trackbacks for "Don’t leave a trace: Private Browsing in Firefox"
  1. […] caratteristica più evidenziata nelle note di rilascio è la modalità di “navigazione privata” grazie a cui è possibile non lasciare tracce dei siti visitati e rimuovere parti della […]