Skip to main content
Cloudflare Bypass

Bypass Cloudflare with Puppeteer

Stop getting blocked by Cloudflare. Bypass Turnstile challenges, bot detection, and WAF rules automatically with stealth Puppeteer in the cloud.

The Cloudflare Problem

Cloudflare protects over 20% of all websites, making web scraping and automation increasingly difficult

Challenge Pages
Cloudflare Turnstile blocks your Puppeteer scripts with challenge pages that require JavaScript and browser fingerprint verification
  • ×Interactive challenges that stop headless browsers
  • ×Device fingerprinting detects automation tools
  • ×Behavioral analysis flags bot-like patterns
Bot Detection
Advanced bot management detects headless Chrome and Puppeteer scripts even without challenge pages
  • ×WebDriver detection blocks automated browsers
  • ×IP reputation blocking from cloud providers
  • ×Rate limiting stops scraping at scale
Solution

The Browserless Solution

Run Puppeteer with built-in Cloudflare bypass - no configuration needed

Stealth Fingerprints
Browser fingerprints automatically randomized to bypass Cloudflare's device fingerprinting. WebDriver flags removed, canvas fingerprinting blocked.
Turnstile Solving
Automatic Cloudflare Turnstile challenge solving with integrated CAPTCHA solving services. Challenges are bypassed transparently.
Residential IPs
Optional residential proxy integration to avoid IP-based blocking from Cloudflare. Appear as real users from any location.

Simple Puppeteer Integration

Just change your WebSocket endpoint - Cloudflare bypass is automatic

Before: Gets Blocked by Cloudflare
Standard Puppeteer scripts are easily detected and blocked
import puppeteer from 'puppeteer';

// This will likely be blocked by Cloudflare
const browser = await puppeteer.launch({
  headless: true,
  args: ['--no-sandbox']
});

const page = await browser.newPage();

// Cloudflare detects headless Chrome and shows challenge page
await page.goto('https://cloudflare-protected-site.com');

// Script fails or gets blocked
const content = await page.content();
await browser.close();
After: Bypasses Cloudflare Automatically
Connect to Browserless for automatic Cloudflare bypass
import puppeteer from 'puppeteer-core';

// Turnstile solving on, with a timeout long enough for a solve to finish
const browser = await puppeteer.connect({
  browserWSEndpoint: 'wss://production-sfo.browserless.io?token=YOUR_API_KEY&solveCaptchas=true&timeout=300000'
});

const page = await browser.newPage();
const cdp = await page.createCDPSession();

// Browserless reports a detected challenge, then the result of its background solve
const challengeFound = new Promise((resolve) =>
  cdp.once('Browserless.captchaFound', () => resolve(true))
);
const challengeSolved = new Promise((resolve) =>
  cdp.once('Browserless.captchaAutoSolved', resolve)
);

await page.goto('https://cloudflare-protected-site.com', {
  waitUntil: 'networkidle2',
  timeout: 60000,
});

// Detection can land just after navigation settles, so allow a few seconds for it.
// If a challenge was served, read the page only once the solve succeeds.
const found = await Promise.race([
  challengeFound,
  new Promise((resolve) => setTimeout(() => resolve(false), 5000)),
]);
if (found) {
  const { solved, error } = await challengeSolved;
  if (!solved) throw new Error(error || 'Challenge was not solved');
}

// Read the protected content
const content = await page.content();
console.log('Successfully bypassed Cloudflare!');

await browser.close();
Advanced: Handle Complex Cloudflare Scenarios
Additional options for tougher Cloudflare protection
import puppeteer from 'puppeteer-core';

// Stealth mode means fewer challenges are served in the first place
const browser = await puppeteer.connect({
  browserWSEndpoint:
    'wss://production-sfo.browserless.io?token=YOUR_API_KEY&stealth=true&solveCaptchas=true&timeout=300000'
});

const page = await browser.newPage();
const cdp = await page.createCDPSession();

// Browserless reports a detected challenge, then the result of its background solve
const challengeFound = new Promise((resolve) =>
  cdp.once('Browserless.captchaFound', () => resolve(true))
);
const challengeSolved = new Promise((resolve) =>
  cdp.once('Browserless.captchaAutoSolved', resolve)
);

// Set a realistic viewport
await page.setViewport({ width: 1920, height: 1080 });

await page.goto('https://cloudflare-protected-site.com', {
  waitUntil: 'networkidle2',
  timeout: 60000,
});

// Detection can land just after navigation settles, so allow a few seconds for it.
// If a challenge was served, read the page only once the solve succeeds.
const found = await Promise.race([
  challengeFound,
  new Promise((resolve) => setTimeout(() => resolve(false), 5000)),
]);
if (found) {
  const { solved, error } = await challengeSolved;
  if (!solved) throw new Error(error || 'Challenge was not solved');
}

// Extract data after the challenge clears
const data = await page.evaluate(() => {
  return {
    title: document.title,
    content: document.body.textContent
  };
});

console.log('Data extracted:', data);
await browser.close();
REST API Alternative
Bypass Cloudflare without writing Puppeteer code
// Use Browserless REST API to bypass Cloudflare
const response = await fetch('https://production-sfo.browserless.io/content', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': 'Bearer YOUR_API_KEY'
  },
  body: JSON.stringify({
    url: 'https://cloudflare-protected-site.com',
    waitFor: 'networkidle2',
    stealth: true
  })
});

const html = await response.text();
console.log('Successfully bypassed Cloudflare:', html);

Why Choose Browserless for Cloudflare Bypass?

Production-ready Cloudflare bypass for Puppeteer at scale

High Success Rate
Turnstile and interstitial challenges are detected and solved automatically, and attempts that don't clear aren't charged. Techniques are updated as Cloudflare changes.
Zero Configuration
Simply connect to Browserless instead of launching local Chrome. Cloudflare bypass is automatic with built-in stealth mode. No complex setup required.
Always Updated
Our team monitors Cloudflare changes and updates bypass techniques automatically. You're always protected against the latest detection methods.
Fast & Reliable
Global edge network ensures fast connections. Enterprise-grade infrastructure with automatic failover and 99.9% uptime.
Residential Proxies
Integrate residential or datacenter proxies to avoid IP blocking. Support for all major proxy providers with seamless configuration.
Same Puppeteer API
All Puppeteer methods work exactly the same. No new API to learn, just change the connection endpoint. 100% compatible.

How Cloudflare Bypass Works

Multi-layered approach to defeat Cloudflare's bot detection

Browser Fingerprint Evasion

Cloudflare analyzes dozens of browser properties to detect automation. We randomize and sanitize fingerprints including user agent, screen resolution, WebGL renderer, audio context, fonts, plugins, and timezone. WebDriver flags are removed completely.

Turnstile Challenge Solving

When Cloudflare presents a Turnstile challenge, our system automatically detects and solves it using integrated CAPTCHA solving services. The challenge is resolved transparently without any code changes.

Behavioral Pattern Matching

Cloudflare tracks mouse movements, keyboard timing, and scroll patterns. Our browsers simulate realistic human behavior with natural timing variations and movement patterns that pass behavioral analysis.

TLS Fingerprint Masking

Cloudflare examines TLS handshakes to identify automated browsers. We use realistic TLS fingerprints that match real Chrome browsers to avoid detection at the network level.

IP Reputation Management

Optional residential proxy integration allows you to route requests through residential IPs, avoiding Cloudflare's datacenter IP blocking. Support for rotating proxies and geo-targeting.

Common Use Cases

Browserless is built for automating systems you own or are authorized to access.

E-commerce Scraping
Extract product prices, reviews, and availability from Cloudflare-protected e-commerce sites for competitive analysis and price monitoring.
Market Research
Collect competitive intelligence and market data from protected business directories to inform strategic decisions.
SEO Monitoring
Track search rankings and SERP features on search engines that use Cloudflare protection for comprehensive SEO insights.
Content Aggregation
Aggregate news, articles, and content from multiple Cloudflare-protected sources for comprehensive content platforms.
Automated Testing
Test web applications and SaaS products that use Cloudflare for DDoS protection without disrupting security measures.

Start Bypassing Cloudflare Today

Run Puppeteer with automatic Cloudflare bypass. No complex setup, no maintenance. The free plan includes 1,000 units to get you started.