Skip to content

Commit 532104b

Browse files
hostname mgmt
1 parent d9ba18a commit 532104b

File tree

1 file changed

+39
-9
lines changed

1 file changed

+39
-9
lines changed

src/content/docs/turnstile/concepts/hostname-management.mdx

Lines changed: 39 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,31 +6,61 @@ sidebar:
66

77
---
88

9+
You can associate hostnames with your widget to control where it can be used using Hostname Management. Managing your hostnames ensures that Turnstile works seamlessly with your setup, whether you add standalone hostnames or leverage zones registered to your Cloudflare account.
10+
11+
## Hostname limits
12+
913
By default, all widgets can have up to 10 hostnames associated with a widget. A widget requires at least one hostname to be entered.
1014

1115
Only Enterprise Bot Management and Enterprise Turnstile customers can have this limit increased. Contact your account team to increase your hostname limit.
1216

13-
You must specify a list of hostnames when creating a widget. The widget can only be used on these hostnames and will not work on any other hostnames. You can use subdomains to restrict the widgets further.
17+
## Add a custom hostname
18+
19+
You can add a hostname to your Turnstile widget even if it is not on the Cloudflare network or registered as a zone. There are no prerequisites for using Turnstile.
20+
21+
To add a custom hostname:
22+
23+
1. Log in to the [Cloudflare dashboard](https://dash.cloudflare.com/) and select your account.
24+
2. Go to **Turnstile**.
25+
3. On an existing widget, select **Settings**.
26+
4. Select **Add Hostnames** under Hostname Management.
27+
5. Add a custom hostname or choose from an existing hostname.
28+
6. Select **Add**.
29+
30+
## Add hostnames with a registered zone
31+
32+
If you already have a zone registered with Cloudflare, you can add hostnames during the Turnstile widget setup. You will see all zones registered to your account, where you can select the relevant hostname from the list, and it will be added to your Turnstile widget seamlessly.
33+
34+
## Hostname requirements
35+
36+
When associating hostnames with a widget, follow these requirements:
1437

15-
The hostname should not contain a scheme `http://` or `https://`, a port `443`, or a path `/`.
38+
- Hostnames must be fully qualified domain names (FQDNs), such as `example.com` or `subdomain.example.com`.
39+
- Wildcards are not supported. Specify each hostname you want Turnstile to work on.
40+
- The hostname should not include:
41+
- A scheme (e.g., `http://` or `https://`)
42+
- A port (e.g., `443`)
43+
- A path (e.g., `/path`)
1644

17-
Specifying a subdomain is optional.
45+
### Subdomain specification
1846

19-
For example, using the `www.example.com` value will allow widgets on the following hostnames:
47+
Specifying a subdomain is optional, but it can be used to further restrict the widget. For example, adding `www.example.com` as a hostname will allow widgets to work on:
2048

2149
- `www.example.com`
2250
- `abc.www.example.com:8080`
2351

24-
but not on the following hostnames:
52+
However, it will not work on the following hostnames:
2553

2654
- `example.com`
2755
- `dash.example.com`
2856
- `cloudflare.com`
2957

30-
When the widget is embedded on a hostname not listed, it will show an error message.
58+
:::note
59+
If the widget is embedded on a hostname not listed, it will display an error message.
60+
:::
3161

32-
## Optional hostname validation
62+
## Optional hostname validation (Enterprise only)
3363

34-
Customers with Enterprise Bot Management or Enterprise Turnstile can have the optional `any hostname` validation entitlement.
64+
For Enterprise customers, optional hostname validation adds an additional layer of security. When enabled, this feature ensures that Turnstile widgets can only load on the specified hostnames.
3565

36-
By default, a widget requires at least one hostname to be entered. With this entitlement, you can create and use a widget without entering any hostnames for the widget. Contact your account team to enable this entitlement.
66+
Hostname validation is not enabled by default and must be explicitly configured in your account settings.

0 commit comments

Comments
 (0)