Table of Contents Previous entry (meta:tag) Next entry (meta:noframes)
This tag defines the domains (no top-level domains) including subdomains which are allowed to be retrieved by GM_xmlhttpRequest
// @connect <value>
<value> can be:
example.com (this will also allow all subdomains).subdomain.example.com.self to whitelist the domain the script is currently running at.localhost to access the localhost.1.2.3.4.*.If it's not possible to declare all domains a userscript might connect to then it's a good practice to do the following:
@connect * to the script to allow Tampermonkey to offer an "Always allow all domains" button.Users can also whitelist all requests by adding * to the user domain whitelist at the script settings tab.
Notes:
@domain tags are interpreted as well.More examples:
// @connect tmnk.net
// @connect www.tampermonkey.net
// @connect self
// @connect localhost
// @connect 8.8.8.8
// @connect *