You are currently viewing a snapshot of www.mozilla.org taken on April 21, 2008. Most of this content is highly out of date (some pages haven't been updated since the project began in 1998) and exists for historical purposes only. If there are any pages on this archive site that you think should be added back to www.mozilla.org, please file a bug.



End User Guide:

"Automatic Proxy Configuration" (PAC)

Abstract:
Short non-technical discussions: What is it? Why do people use it? What are common problems?
This article supplements the existing built-in help files.

Audience:
Mozilla end users, blackbox testers, and system administrators.
This article assumes that the reader understands the purpose of proxy servers, and manual proxy configuration, as well as basic networking terms like URL, proxy server.

What is Automatic Proxy Configuration (PAC)?

Automatic Proxy Configuration is a proxy mode where the proxy configuration is described in a file (using JavaScript), called a PAC (.pac) file. The file is maintained by the network administrator and requires no user updating (hence "automatic"). As a browser user, you only need a URL provided by your systems or network administrator.

Why do people use it?

PAC has two advantages over normal configurations:
  1. Network-based PAC files are centrally administered, and easy to update.
    Network administrators usually share the PAC files via HTTP or FTP. If there are server changes or network outages, the PAC file can be changed, and your browser configuration will be automatically updated when the new PAC file is loaded.
  2. You can use complicated network environments with a single configuration.
    PAC has support for load balancing and failover. These features can make your browsing experience faster or more reliable, and are not possible with a manual configuration. Your manual proxy configuration is prety complicated in comparison.
Things end users should know about Mozilla and PAC:

Mozilla is not the only browser that supports PAC (for example, IE and Safari do too), but there are some Mozilla-specific things you should know:
  1. Error messages are in the JavaScript Conole

    If something goes wrong, you should check the JavaScript console. Many common error messages will go to the Tools | JavaScript Console.
    (I did mention this was JavaScript based, didn't I?)

  2. Mozilla errors when I startup sometimes.

    Sometimes, the first page I go to gives an error, after that it works fine.
    The Mozilla version of PAC has a problem with the first request if your PAC server is slow. The workaround is to save the PAC file locally. Check w/ your network administrator to see if they regularly change the pac files (most do not).

  3. My PAC file makes Mozilla seem slow.

    On rare occassions, users complain that browsing with a PAC file is slow. This can be caused by very large or complicated code in your PAC file. Have the network administrator look at the Technical Guide to PAC for more information.

  4. A proxy is a server, PAC is a file.

    When you configure PAC, make sure you use a URL (like http://proxy/file.pac). You cannot use a hostname (proxy.domain or proxy:8080)

  5. Reloading updated PAC files.

    PAC will reload anytime you change the URL or press the "reload" button in the Proxy Preferences. PAC will not reload if you change the proxy configuration type to PAC and the PAC file was previously loaded.

Final point:

  • PAC has a lot of uses which are not detailed here. If you want to learn more about PAC (usually to modify or create your own file) you can use a PAC file saved to your local disk (via a file: URL). See the technical guide to PAC for more information.
NOTE: this guide is for end users, which is why it has no bug references. Please read the technical guide to PAC before commenting in any bugzilla reports.