DEV Community

Phaneendra Kanduri
Phaneendra Kanduri

Posted on

How I Stumbled Into Cloudflare Before It Took Over the Internet (2017)

The problem: WordPress site loading in ~10s. No git. No control. Just pain.

I tried the classic frontend interview answer for website optimization:

  • Moved external JS to end of body
  • Moved external CSS to head
  • Photoshopped images down to reasonable sizes

Result: 10s → 9s. Not a win.

I had no access to WordPress's default JS/CSS bundles. Database queries ran on every page load. I was stuck.

Desperation research

I needed to understand how websites actually load, not just frontend theory. But the full network layer, browser rendering pipeline, and WordPress's request-response cycle.

StackOverflow felt too high-stakes for what I thought was a basic question. Google and WordPress plugin repositories were my starting point.

Most WordPress developers reach for a plugin first. I did too. None of them solved the problem.

Then I found the term: CDN.

During this research, I also discovered Automattic, the company behind WordPress. I have a habit of checking parent companies ever since I learned Alphabet owns Google. Finding Automattic made me realize for the first time: there are companies building infrastructure that runs the internet at scale.

Enter The Cloudflare

CDN research surfaced two main options: Akamai and Cloudflare. Cloudflare's free tier and DNS-level integration made it the obvious choice for a small company with no DevOps budget.

I researched DNS configuration, got approval from my manager for a trial run, changed the DNS records, and waited 24 hours for propagation.

Result: 10s → 0.9s.

The client emailed us unprompted: "Website is really fast now. Only the chatbot is slow."

The chatbot had a setTimeout(2000) to let the page load first. I removed it immediately.
Enter fullscreen mode Exit fullscreen mode

It felt like I'd been trying to drain a swimming pool with a bucket until I found the pump.

What stuck with me

That 10s → 0.9s improvement taught me that infrastructure solves problems code optimization alone can't touch. It's why I now evaluate CDN strategy, edge caching, and origin offloading as first-order concerns in any performance audit, not afterthoughts.

Key takeaways:

  • CDNs solve problems frontend optimization alone can't touch
  • Sometimes the answer isn't in your code. It's in understanding how infrastructure works at scale
  • Cloudflare was already solving the right problems in 2017, long before it became ubiquitous

Top comments (0)