Scared Off Servers by Hacks: My Cloudflare Pages Migration

After finishing the coupon tool, I needed to put it online. I was about to buy shared hosting when it hit me — it's just an HTML file. Why pay for a server?

Where I Got Burned Before

My old blog ran on WordPress with an Alibaba Cloud server — 300+ yuan a year, and if I forgot to renew it died. Every time the panel updated or I installed one more plugin, the CPU alarm went off. Worst was when it got hacked and someone injected a gambling page. I stayed up half the night cleaning it out. After that I have a phobia of "servers."

So this time I refused to touch servers. Tried Vercel — custom domains require credit card verification which I don't have. Tried Netlify — free build limits are too tight. Then tried Cloudflare Pages: drag the folder in, wait 30 seconds, done. Subdomain codes.webproctools.com auto-resolved because my main domain is already on Cloudflare. I never even touched the DNS settings page.

It Really Is Drag-and-Drop

Log in to Cloudflare, go to Pages, drag the whole folder in, wait 30 seconds. Bind the subdomain, DNS configures itself, SSL issues automatically. Compare that to the old way: buy server, install OS, configure Nginx, apply for SSL, upload files — half a day minimum.

I Tweaked Caching Multiple Times

I deployed without any config first, updated a file, and users still saw the old version. Turns out it was CDN caching. I added a _headers file: HTML not cached, CSS/images cached for a week. That way content updates go live immediately while static assets stay fast.

I got this wrong twice. First I set CSS to no-cache too, so every style update required waiting for CDN purge. Then I wrote /* instead of /** in the path pattern, which meant nothing was cached — CDN was pointless. No error, just slow. Took me a day to figure it out.

Subdomains for Multiple Tools

My plan: main domain webproctools.com for the blog, subdomains for tools. codes.webproctools.com is the coupon tool, more to come. Each is a separate Pages project — isolated. If one breaks, the others keep running.

I used to think each tool site needed its own server. Now I realize one domain plus N subdomains is enough, all free. Just pay for the domain annually.

The Honest Truth

I'm not a developer. I used to think "deployment" was something professional. Turns out static sites don't need ops at all. Cloudflare Pages is made for people like me — can write some HTML, don't want to mess with servers, just want a website.

Watch out for the _headers path syntax. One wrong character and caching silently doesn't work — no errors, just slow. That's how I lost a day.