UrlList syntax reference Stay organized with collections Save and categorize content based on your preferences.
This guide explainsUrlList syntax for Secure Web Proxy.
UrlList lets you create many match entries that you can reuse across multiplerules.
UrlList syntax supports matching domains in full or by suffix, and URLs withfull path with no parameters or a prefix path.
Supported wildcards
UrlList supports the* asterisk wildcard character, which you can use as aprefix to match partial subdomains or partial paths.
When you provide partial domains,UrlList matches only complete subdomaintokens. If a path separator isn't provided, thenUrlList matches any path. Forexample, if you provideexample.com, thenUrlList matchesexample.com/*,including all paths in the domain.
HowUrlList interprets entries
Secure Web Proxy uses theUrlList patterns that you provide to match againstURLs and then determine whether the URL is allowed or disallowed.
UrlList interprets entries according to the following:
Entries that contain a period (
.) and a forward-slash (/) must bewell-formed URLs. You can include subdomain and path wildcards. The token tothe left of the first/character is interpreted as the top-level domain,such as.comingoogle.com/news.Entries that contain a period (
.) and that don't contain a forward-slash (/) areinterpreted as domains. You can include the subdomain wildcard. Therightmost token in this case is interpreted as the top-level domain, such as.xyzinabc.xyz.All other entries are invalid.
When aUrlList pattern is matched against values that contain aforward-slash (/), such as inrequest.url(), patterns are interpreted as explainedpreviously. However, when aUrlList pattern is matched against values without a/, such as inhost(), only the domain portion of the pattern is matched.
Pattern matching examples
The following table shows example patterns, example URLs that each patternmatches, and example URLs that each pattern does not match.
| Pattern | Matches | Does not match |
|---|---|---|
*example.com | example.com/ server.example.com/ sample.server.example.com/ example.com/path example.com/path?q=query example.com/path/subpath sample.server.example.com/path/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com |
*.example.com | server.example.com/ sample.server.example.com/ sample.server.example.com/path/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com example.com/ example.com/path example.com/path/subpath |
example.com | example.com/ example.com/path example.com/path/subpath | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com server.example.com/ sample.server.example.com/ sample.server.example.com/path/ |
*server.example.com | server.example.com/ sample.server.example.com/path sample.server.example.com/path/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com example.com/ example.com/path example.com/path/subpath |
*example.com/ | example.com/ server.example.com/ sample.server.example.com/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com example.com/path/ example.com/path/subpath sample.server.example.com/path/ |
*example.com/path* | example.com/path example.com/path/subpath sample.server.example.com/path/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com example.com/ server.example.com/ sample.server.com/ |
*example.com/path/* | example.com/path/subpath sample.server.example.com/path/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com example.com/ server.example.com/ sample.server.example.com/ example.com/path |
*example.com/path/ | sample.server.example.com/path/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com example.com/ sample.example.com/ sample.server.example.com/ example.com/path example.com/path/subpath |
example.com/ | example.com/ | myexample.com/ example.com.bad.com/ us13.altostrat.com/go/example.com/path www.google.com/search?q=example.com server.example.com/ sample.server.example.com/ example.com/path example.com/path/subpath sample.server.example.com/path/ |
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-11-24 UTC.