Updated answer for Linux, Sept 2020
I know the original question was for Windows, but the answers and comments clearly show appetite for an answer for Linux too. This is an update to
@tacoscool's answer which is very helpful, but only covers the ExternalProtocolDialogShowAlwaysOpenCheckbox
policy for ensuring the "Always open..." checkbox is visible.
If instead you want to skip the dialog for a certain protocol (e.g. tel:...
, or org-protocol:...
for capturing within Emacs's Org mode) across all sites without any prompting, as requested by the original question, you need to use the URLWhitelist
policy for Chrome 85 and earlier, and URLAllowlist
for Chrome 86 and later. If you are on 85 or earlier but want a future-proof solution, you can combine them both into a single file, e.g.
sudo bash
mkdir -p /etc/opt/chrome/policies/{managed,recommended}
cat <<EOF >/etc/opt/chrome/policies/managed/allow_tel_protocol.json
{
"URLWhitelist": [
"tel:*"
],
"URLAllowlist": [
"tel:*"
]
}
EOF
Presumably this file could be placed in /etc/opt/chrome/policies/recommended
instead of /etc/opt/chrome/policies/managed
but I haven't tested that.
You can verify that these files are having the correct effect by visiting chrome://policy
.
Note that this is a policy which will take effect for all users. If you want to set it per user then I think you have to find the equivalent key in the user profile's preferences JSON file, which is typically ~/.config/google-chrome/Default/Preferences
or similar on Linux. According to other posts, it should be enough to ensure that you have something like
"protocol_handler":{"excluded_schemes":{"tel":false}}
in this Preferences
file (I wonder why it's false
not true
, but OK whatever...). However when I shut down Chrome, edited the file, and restarted Chrome, it automatically removed that setting every time. Maybe I was doing something wrong, or maybe this no longer works - I'm on Chrome 85.
Finally, if you want to achieve the same in Chromium or Brave, replace all mentions above of /etc/opt/chrome
with /etc/chromium