Cloudflare Turnstile
Intro
This is another free service from Cloudflare. I decided to add to my site, because why not!
Cloudflare Dashboard
- Log into your Cloudflare Account
- On the left nav go to Application Security -> Turnstile
- Click Add Widget
- Name your widget
- Add the Hostnames you would like to cover
- I chose Managed for Widget Mode
- Opting out of pre-clearence for now. I might tackle this in a future blog post. However, cf_clearence cookie I found in my last blog post makes a re-appearence.
- Click Create Widget
In The HTML
I am mostly following Cloudflare Documentation.
I ended up adding the following HTML to my website and the blog you are reading now:
<div
class="cf-turnstile"
data-sitekey="<site-id>"
data-theme="light"
data-size="normal"
data-callback="onSuccess">
</div>
This worked! However, it did not really fit with the styling for my website. So, I changed the widget mode option to invisible.
Now it keeps the flow of the site without the interruption of the visible widget. This is fine for my low traffic informational website.