.PAC

Файл PAC

Proxy Auto-Config File
Задать вопрос
БЫСТРЫЙ ОТВЕТ

A PAC file (Proxy Auto-Config) is a small JavaScript file that tells your browser or OS which proxy server to use for each URL, or whether to connect directly. To read or edit it, open it in any text editor - it is plain text. To use it, enter its URL or path in your browser or OS proxy settings under "Automatic proxy configuration.

Разработчик: Netscape Communications (original author of the PAC standard, 1996) Категория: Интернет-файлы Открыть стандартное MIME: application/x-ns-proxy-autoconfig
ОТКРЫВАЕТСЯ НА Windows macOS Linux
Связанные: .CRDOWNLOAD · .JNLP · .WEBARCHIVE · .PART

На этой странице

Проиндексировано расширений: 19k+
Последняя проверка: Jun 20, 2026

Не знаете, что это за файл?

Перетащите любой файл в наш идентификатор - мы прочитаем первые байты, чтобы определить формат.

Идентифицировать файл

Что такое формат файла PAC?

A .pac file, also known as a Proxy Auto-Config file, is a configuration file used by web browsers and operating systems to automate proxy server connection settings. The .pac file contains a single JavaScript function - FindProxyForURL(url, host) - that specifies which connection mode to use when a browser needs to access a given URL. The function can return DIRECT (connect without a proxy), PROXY host:port (route through an HTTP proxy), or SOCKS host:port, and multiple directives may be chained with semicolons as fallbacks.

The format was introduced by Netscape Communications in 1996 and has remained the de-facto standard for proxy auto-configuration ever since. Because a .pac file is plain JavaScript, it can use built-in PAC helper functions - isInNet(), dnsDomainIs(), shExpMatch(), dnsResolve(), and others - to build complex per-URL routing logic. Extended functions such as isInNetEx() added around 2010 provide IPv6 support.

.pac files are plain text and can be created or edited in any text editor on Windows, macOS, or Linux. In enterprise and network environments they are often distributed automatically via the Web Proxy Auto-Discovery (WPAD) protocol, where the file is served under the well-known name wpad.dat - the same script content in a .dat wrapper. The browser fetches and executes the script each time it connects to a new host. All major browsers - Chrome, Firefox, Edge, and Safari - support .pac files on Windows, macOS, Linux, iOS, and Android.

Безопасность и защита

РИСК: MEDIUM

A PAC file is not executable on your system the way a program is - it runs only inside the browser's restricted PAC engine. But it IS security-relevant: because it decides where ALL your web traffic is routed, a malicious or tampered PAC can silently send your traffic (including bank logins) through an attacker's proxy for interception. Unexpected "automatic proxy configuration" settings or a planted .pac/wpad.dat are recognized malware indicators. Only apply PAC files from your own IT department or a source you trust, inspect the FindProxyForURL logic (it's readable plain text), and be wary of WPAD on untrusted networks, which can be hijacked.

Детали формата

в двух словах
ПОЛНОЕ НАЗВАНИЕProxy Auto-Config Fileтакже известен как PAC file, Proxy Auto-Configuration script
РАЗРАБОТЧИКNetscape Communications (original author of the PAC standard, 1996)с 1996 (Netscape Navigator 2.0 proxy auto-config)
КАТЕГОРИЯИнтернет-файлы
MIME-ТИПapplication/x-ns-proxy-autoconfig
ТИПPlain-text JavaScript file defining one function, FindProxyForURL()
СТАНДАРТОткрытый · без роялти
Это расширение также используется в…
  • Atari STAD image (PackBits) - Obscure compressed bitmap image format from the Atari ST 'STAD' paint program.
  • SAMS ARchive (.pac) - Compressed archive created by the SAMS ARchiver packing utility.
  • Tencent QQ data file - Internal data/resource file used by the Tencent QQ messenger.

Программы, открывающие файлы PAC

Windows2 apps
Notepad / VS Code (edit) Бесплатно Right-click → Open with → Notepad (or VS Code) to read/edit the JavaScript. To USE it: Settings → Network & internet → Proxy → 'Use setup script' → enter its URL/path.
Web browser (apply, not view) Бесплатно In the browser/OS proxy settings choose 'Automatic proxy configuration URL' and point it at the .pac - the browser runs it, it doesn't display it.
macOS2 apps
TextEdit / VS Code (edit) Бесплатно Open in TextEdit/VS Code to read or edit. To USE it: System Settings → Network → Proxies → 'Automatic Proxy Configuration' → enter the file/URL.
Safari (apply via System Settings) Встроенная Safari uses the system proxy; set the PAC under System Settings → Network → Proxies.
Linux2 apps
Any text editor (edit) Открытый код Edit with nano/gedit/VS Code. Apply via the desktop's network proxy settings ('Automatic' → PAC URL) or per-app (e.g. GNOME Settings → Network → Proxy).
Firefox (apply) Открытый код Settings → Network Settings → 'Automatic proxy configuration URL' → enter the .pac location.

Технические подробности

глубокая спецификация
File typePlain-text JavaScript source file
Core functionFindProxyForURL(url, host) - the single required entry point the browser calls for each connection
MIME typeapplication/x-ns-proxy-autoconfig (also accepted: text/plain, application/x-javascript-config)
Text encodingASCII / UTF-8
Typical file sizeUnder 5 KB; large enterprise scripts may reach tens of KB
Binary signatureNone - identified by the presence of the FindProxyForURL() function declaration
Return value syntaxDIRECT, PROXY host:port, or SOCKS host:port; multiple directives chained with semicolons for fallback
Built-in helper functionsisInNet(), dnsDomainIs(), shExpMatch(), dnsResolve(), myIpAddress() and related PAC utilities
IPv6 extensionisInNetEx(), isResolvableEx() and other Ex-suffixed helpers added ~2010 for IPv6 address matching
WPAD integrationServed as wpad.dat under the Web Proxy Auto-Discovery (WPAD) protocol for network-wide auto-distribution
Distribution methodBrowser or OS fetches the file via an HTTP/HTTPS URL configured in system or browser proxy settings
Execution contextRestricted JavaScript sandbox - no DOM access, no arbitrary network calls; only PAC helper functions permitted
Supported platformsWindows, macOS, Linux, iOS, Android - any OS or browser that supports proxy configuration
Well-known filenamesproxy.pac (direct URL config) and wpad.dat (WPAD auto-discovery)
Выпущен1996 (Netscape Navigator 2.0 proxy auto-config)
Последняя версияDe-facto stable since 1996; Microsoft added IPv6 helper functions (ex versions) ~2010
Открыть стандартноеДа · без роялти
Спецификацияdeveloper.mozilla.org

Конвертации PAC

Вопросы и ответы сообщества

спрошено пользователями
Задать быстрый вопрос
Получите помощь от людей, работающих с файлами PAC. Будьте конкретны - укажите вашу систему и версию ПО.
Аккаунт не нужен · ответы обычно в течение дня

Вопросов пока нет - станьте первым, кто спросит о файлах PAC.

Часто задаваемые вопросы

What is a PAC file?
A Proxy Auto-Config file - a small JavaScript file with one function, FindProxyForURL(), that tells your browser or OS which proxy server to use for each website (or to connect directly).
How do I open a PAC file?
To read or edit it, open it in any text editor (Notepad, TextEdit, VS Code) - it's plain text. To actually USE it, enter its URL/path in your browser or OS proxy settings under 'Automatic proxy configuration'.
How do I edit a PAC file?
Open it in a code editor and modify the FindProxyForURL function - add domains, change the proxy host:port, or return 'DIRECT' for sites that should bypass the proxy. Test before deploying; a syntax error breaks proxying.
Why is a PAC file blocking some websites?
The PAC's logic is routing those URLs to a proxy that's down or denying them. Inspect FindProxyForURL to see which rule matches, or temporarily switch your proxy setting to 'No proxy' to confirm the PAC is the cause.
Is a PAC file dangerous?
It can be. A malicious PAC can reroute all your traffic through an attacker's proxy. If you find an unexpected proxy auto-config setting or .pac file you didn't add, treat it as a possible compromise and remove it.
What's the difference between a PAC file and wpad.dat?
Same format. A .pac is a PAC file you point at manually; wpad.dat is the identical content served at a well-known name so clients find it automatically via the WPAD protocol.

Ссылки

1MDN - Proxy Auto-Configuration (PAC) filedeveloper.mozilla.org
2Microsoft - Use a setup script / automatic proxy configurationlearn.microsoft.com

Узнать больше

по всей базе данных

Популярные расширения на этой неделе

1.AQQAQQ Instant Messenger File
2.CRDOWNLOADChrome Partial Download File
3.DATProgram Data File (generic)
4.EXEWindows Executable (Portable Executable)
5.RPMSGRestricted Permission Message
6.JPGJPEG Image
7.PARTPartial Download File
8.ICSiCalendar data file
9.BINCD/DVD Disc Image (BIN/CUE)
10.JSONJavaScript Object Notation file

Похожие расширения

.CRDOWNLOADChrome Partial Download File
.JNLPJava Network Launch Protocol file
.WEBARCHIVESafari Web Archive
.PARTPartial Download File
.DOWNLOADPartial / Incomplete Download File
.ASPXActive Server Page Extended (ASP.NET Web Form)

Бесплатные инструменты для файлов

Идентификатор файлов и конвертер изображений в браузере - все работает на вашем устройстве.

Открыть инструменты

Обзор расширений файлов A-Z