This guide explains how to prevent users from opening local files using the file:// protocol on managed devices. Blocking the file:// protocol closes a common bypass path for URL-based filtering and ensures that users can access only approved web content through monitored browsers and managed network paths.
Before you begin
You must have administrator access to Google Admin Console, Microsoft Intune admin center, or Jamf.
You must have administrator access to your school’s managed devices.
Important
Blocking file://* prevents access to all local files, such as HTML, PDFs, graphics, and sound files, in web browsers. Plan accordingly to ensure this doesn’t affect your organization’s workflows, internal or offline tools, or local help files.
Chromebook
Follow these steps to block local files in Chromebook via Google Workspace.
Sign in with your Administrator account in the Google Admin console.
Go to Devices > Chrome > Settings > Users & browsers.
Select the relevant school or organization.
Under URL Blocking, find the URL blocklist setting.
Add file://*.
Save the setting.
Note
These steps are only general guidelines. For up-to-date information, always refer to Google Workspace’s documentation.
Windows
Use Microsoft Intune to create a new policy that adds that same rule to block file://.
Configure Microsoft Edge via Intune
In Intune, go to Devices > Manage devices > Configuration and create a new policy.
Choose the platform (Windows or macOS).
Set the Profile type to Settings catalog and select Create.
In the Configuration settings, select Add settings.
Search for URLBlocklist.
Filter the results to Microsoft Edge and select Block access to a list of URLs (Device).
Add file://*
Configure Microsoft Edge using Group Policy
Go to Computer configuration > Administrative Templates > Microsoft Edge.
Find URLBlocklist
Add file://*
Chrome for Windows
Intune includes ADMX import for Chrome by default. However, you can still upload the templates if they’re not available in the Intune admin center. Skip to 2: Configure Chrome if the templates are already in Intune.
1: Upload the templates
Download and unzip the free Chrome Enterprise bundle from Google. You’ll need the google.admx and chrome.admx files.
In Intune, go to Devices > Configuration > Import ADMX> Import and upload google.admx, followed by chrome.admx.
Note
You must import google.admx first to prevent the “NamespaceMissing:Google.Policies” error. Always consult Microsoft’s documentation for instructions and requirements for importing third-party ADMX templates into Intune.
2: Configure Chrome
In Intune, create a new policy in Devices > Manage devices > Configuration.
Ensure Windows 10 and later is selected for your Platform.
For Profile type, go to Templates > Imported Administrative templates (Preview).
In Configuration settings, locate the imported Chrome categories and find Block access to a list of URLs.
Add file://* as a blocked pattern, then continue through Scope tags and Assignments as normal.
Chrome for macOS
Deploy a configuration profile containing the com.google.Chrome payload, and set URLBlocklist to ["file://*"].
In Jamf, go to Configuration Profiles > New and configure your General payload settings.
Go to Application & Custom Settings > Upload > Add and fill in the Preference Domain field.
Upload your plist file.
Set your Scope and save your settings.
Note
Note: As MDM solutions for Apple devices vary, consult your provider’s documentation for the latest instructions. Refer to Chrome Enterprise Policy deployment with Jamf School for the latest instructions.
Android
Chrome for Android uses the URLBlocklist managed configuration key, mirroring the desktop browser's behavior.
Intune
In the Intune admin center, go to Apps > App configuration policies > Add.
Target the Chrome application and define the URLBlocklist configuration key as a String with the value ["file://*"].
Note
See "Configure Google Chrome for Android Devices Using Intune" for detailed instructions and requirements.
Google Workspace
Sign in to the Google Admin console and go to Devices > Mobile & endpoints > Settings > Android.
Under Managed configurations for Chrome, locate the restriction field and define the restriction key as URLBlocklist.
Ensure Value type is set to String.
Set Configuration value to [“file://*”]
Save your configuration.
Note
The steps above are for general guidance only. Refer to Chrome Enterprise’s guidance for up-to-date information.
Summary
Platform |
Native coverage |
Known gap |
|---|---|---|
Windows (Edge) |
Full |
None |
Windows (Chrome) |
Full, via ADMX import |
None |
macOS (Chrome) |
Full |
None |
macOS (Safari) |
Partial (allowed-list only) |
No native scheme blocklist |
ChromeOS |
Full |
None |
Android (Chrome) |
Full |
None |