Cloudflare Integration Guide

If you want to integrate Index Render into your site, the best approach is to incorporate it into your CDN if one is available. This integration uses the ESM JavaScript syntax in Cloudflare Workers.

Important: Before proceeding, ensure you have access to Cloudflare (at least Worker Admin). This integration only works if Cloudflare is set up as your proxy.

DNS Configuration

  • Ensure the A record or CNAME record is set to Proxied.
  • If issues occur using an A record, replace it with a CNAME record.

AI Crawlers Setting

Note: Cloudflare blocks AI training crawlers by default on new domains. To allow AI crawlers:
  • Go to Account Home
  • Select your domain
  • On Overview page → Enable AI Crawlers under “Control AI Crawlers”

Step-by-Step Guide

1. Create a New Worker

  1. Open Cloudflare Dashboard.
  2. Go to Compute & AI → Workers & Pages.
  3. Click Create Application.
  4. Select Start with Hello World!
  5. Name it (e.g., indexrender.io Worker).
  6. Click Deploy.
  7. Edit Code and replace default code with Index Render worker source code from GitHub.

2. Configure the Worker

  1. Go to Worker Settings.
  2. Under Domains & Routes → Add Route.
  3. Set route like *example.com/*
  4. Select Failure Mode: Fail Open (Proceed)
  5. Save settings.

Route Examples

Website Type Route Pattern
example.com example.com/*
www.example.com www.example.com/*
Both with/without www *example.com/*
Any subdomain *.example.com/*
Specific subdomain blog.example.com/*

3. Add Index Render Token

  1. Go to Variables & Secrets.
  2. Type: Text
  3. Variable Name: INDEX_RENDER_TOKEN
  4. Value: Your indexrender.io token (from Security & Access).

4. Deploy the Worker

After deployment, it may take a few minutes for the integration to start working.

Disable Automatic Signed Exchanges (SXGs)

Usage Warning: If SXGs are enabled, Cloudflare may show cached versions from search results. Since Index Render generates static HTML for bots, we strongly recommend disabling SXGs.

To disable:
Go to Speed → Optimization → Other and turn off Automatic Signed Exchanges.

Verify Installation

  • Test other pages for Index Render headers/IDs.
  • If headers are missing, integration may not be working.

Troubleshooting

If you see the error "Index Render Integration Not Detected", refer to the troubleshooting guide in your Index Render dashboard.

Expert Assistance

Kickstart Package — $800 (one-time) • Three setup & configuration sessions
• Onboarding assistance
• Security assessment