Connect Cloudflare and your domain
Sign in to Cloudflare, let your agent create your site's storage, and point your domain at it.
Cloudflare hosts your site, its data and its stats. The free plan is enough to start.
1. Make an account and sign in
Sign up at cloudflare.com. Then your agent signs in for you: it opens your browser once and you click Allow.
2. Let your agent create the storage
Your agent runs the setup, which creates your site's storage and its analytics database on your account and writes their ids into your config. Until you add a domain, your site lives at <your-site>.<your-name>.workers.dev.
3. Add your domain
- Add your domain to Cloudflare (Add a domain), and change the nameservers at the company you bought it from to the two Cloudflare gives you.
- Wait until Cloudflare says the domain is Active (minutes to a few hours).
- Tell your agent the domain. It sets it in the config and redeploys;
wwwandhttpare sent to your main address automatically.
Working without a browser?
In a cloud session, make an API token instead: My Profile → API Tokens → Create Token → "Edit Cloudflare Workers" template, plus one permission the template lacks: Account → D1 → Edit. Put it in .env as CLOUDFLARE_API_TOKEN=… with CLOUDFLARE_ACCOUNT_ID=….
FAQ
My domain is already on another host.
Moving the nameservers to Cloudflare moves the whole domain. Ask your agent to list the DNS records you need to keep (email, other sites) before you switch; Cloudflare usually copies them for you.
Can I change domains later?
Yes. Add the new one, and your agent can send every page of the old address to the same page on the new one.