Web scraping - what is HTTP 520 status code?

by scrapecrow Dec 16, 2022

Response status code 520 generally means the server failed to generate a valid response (Often related to Cloudflare). This could be caused by technical issues however in web scraping this can also mean insufficient request details or web scraper blocking.

To avoid status code 520 when web scraping ensure that sent requests contain all required headers like secret/CSRF tokens, Origin, Referer and other commonly required details. If it's a POST request make sure the sent body matches expected format.

Otherwise, it's possible the scraper is being identified and blocked. For that refer to our how to scrape without being blocked guide which covers all of the ways to prevent web scrapers from being identified.

Related Articles

Bypass Proxy Detection with Browser Fingerprint Impersonation

Stop proxy blocks with browser fingerprint impersonation using this guide for Playwright, Selenium, curl-impersonate & Scrapfly

PROXIES
SELENIUM
PLAYWRIGHT
PUPPETEER
BLOCKING
Bypass Proxy Detection with Browser Fingerprint Impersonation

What is Rate Limiting? Everything You Need to Know

Discover what rate limiting is, why it matters, how it works, and how developers can implement it to build stable, scalable applications.

BLOCKING
CRAWLING
HTTP
What is Rate Limiting? Everything You Need to Know

How to Choose the Best Proxy Unblocker?

Learn how to choose the best proxy unblocker to access blocked websites. Explore proxies, VPNs, and Scrapfly for bypassing restrictions safely.

PROXIES
BLOCKING
How to Choose the Best Proxy Unblocker?

Alternatives to Cloudscraper to Bypass Cloudflare

Learn why Cloudscraper is outdated and explore modern alternatives for bypassing Cloudflare protections effectively and ethically.

BLOCKING
Alternatives to Cloudscraper to Bypass Cloudflare

What is Error 1015 (Cloudflare) and How to Fix it?

Discover why you're seeing Cloudflare Error 1015 and learn effective ways to resolve and prevent it.

BLOCKING
HTTP
What is Error 1015 (Cloudflare) and How to Fix it?

HTTP Error 503 Service Unavailable and How to Fix it?

Understand what causes HTTP 503 errors, when they might indicate blocking, and how to effectively mitigate them.

API
HTTP
BLOCKING
HTTP Error 503 Service Unavailable and How to Fix it?