PINGDOM_CHECK

#ExtractSummit2026 The world's largest web scraping conference returns. Austin Oct 7–8 · Dublin Nov 10–11.

Register now
Data Services
Pricing
Login
Try Zyte APIContact Sales
  • Unblocking and Extraction

    Zyte API

    The ultimate API for web scraping. Avoid website bans and access a headless browser or AI Parsing

    Ban Handling

    Headless Browser

    AI Extraction

    SERP

    Enterprise

    DocumentationSupport

    Hosting and Deployment

    Scrapy Cloud

    Run, monitor, and control your Scrapy spiders however you want to.

    Coding Agent Add-Ons

    Agentic Web Data

    Plugins that give coding agents the context to build production Scrapy projects. Starts with Claude Code.

  • Data Services
  • Pricing
  • Browse

    • BlogArticles, podcasts, videos
    • Case studiesCustomer outcomes
    • White papersIn-depth reports
    • EventsConferences, webinars, recordings

    Subscribe

    • NewsletterSwiftly delivered
    • Discord communityExtract Data community
  • Product and E-commerce

    From e-commerce and online marketplaces

    Data for AI

    Collect and structure web data to feed AI

    Job Posting

    From job boards and recruitment websites

    Real Estate

    From Listings portals and specialist websites

    News and Article

    From online publishers and news websites

    Search

    Search engine results page data (SERP)

    Social Media

    From social media platforms online

  • Meet Zyte

    Our story, people and values

    Contact us

    Get in touch

    Support

    Knowledge base and raise support tickets

    Terms and Policies

    Accept our terms and policies

    Open Source

    Our open source projects and contributions

    Web Data Compliance

    Guidelines and resources for compliant web data collection

    Join the team building the future of web data
    We're Hiring
    Trust Center
    Security, compliance & certifications
Login
Try Zyte APIContact Sales

Zyte Developers

Coding tools & hacks straight to your inbox

Become part of the community and receive a bi-weekly dosage of all things code.

Join us
    • Zyte Data
    • News & Articles
    • Search
    • Social Media
    • Product
    • Data for AI
    • Job Posting
    • Real Estate
    • Zyte API - Ban Handling
    • Zyte API - Headless Browser
    • Zyte API - AI Extraction
    • Web Scraping Copilot
    • Zyte API Enterprise
    • Scrapy Cloud
    • Solution Overview
    • Blog
    • Webinars
    • Case Studies
    • White Papers
    • Documentation
    • Web Scraping Maturity Self-Assesment
    • Web Data compliance
    • Meet Zyte
    • Jobs
    • Terms and Policies
    • Trust Center
    • Support
    • Contact us
    • Pricing
    • Do not sell
    • Cookie settings
    • Sign up
    • Talk to us
    • Cost estimator
All articles
AI-assisted data extraction28, 28 articles
Data gathering for AI6, 6 articles
Large Language Models (LLMs)24, 24 articles
Tool-assisted coding3, 3 articles
Developer interest143, 143 articles
Integration13, 13 articles
Open-source96, 96 articles
Scraping practice59, 59 articles
Scraping strategy46, 46 articles
Anti-ban35, 35 articles
Traffic6, 6 articles
Web data application25, 25 articles
Web data collection358, 358 articles
Web data collection ethics3, 3 articles
Web data collection legality16, 16 articles
Web scraping APIs63, 63 articles
Zyte API59, 59 articles
Scrapy48, 48 articles
Scrapy Cloud10, 10 articles
Web Scraping Copilot12, 12 articles
AI & Machine Learning1, 1 articles
Automotive2, 2 articles
E-commerce & retail26, 26 articles
Entertainment & Streaming2, 2 articles
Financial Services8, 8 articles
Government2, 2 articles
Market Research & Intelligence3, 3 articles
Media & publishing8, 8 articles
Real Estate2, 2 articles
Recruitment & HR3, 3 articles
Transportation & Logistics2, 2 articles
Travel & hospitality2, 2 articles
Extract Summit25, 25 articles
PyCon1, 1 articles

Appearance

Discord Community
BlogHandling BansScale Up Your Scrapy Projects With Smart Proxy Manager
ArticleHandling Bans

Scale Up Your Scrapy Projects With Smart Proxy Manager

If you want to extract large amounts of data reliably you need efficient proxy management. Smart Proxy Manager does precisely that.

J

John Campbell

3 min read · July 1, 2021

Scale Up Your Scrapy Projects With Smart Proxy Manager

Scale up your Scrapy projects with Smart Proxy Manager

In this tutorial, you will learn how to use smart proxy manager to scale up your already existing Scrapy project in order to make more requests and extract more web data.

Scrapy is a very popular web crawling framework and can make your life so much easier if you’re a web data extraction developer. Scrapy can handle many web scraping jobs including URL discovery, parsing, data cleaning, custom data pipelines, etc… But there’s one thing that Scrapy cannot do out of the box and it has become a must if you want to extract large amounts of data reliably: proxy management.

In order to scale up your Scrapy project, you need a proxy solution.

I will show you how to turn your already existing Scrapy spider and boost it with proxies!

Getting started

For this example, I’m going to use the “Scrapy version” of the product extractor spider that contains two functions:

  1. A crawler to find product URLs
  2. A scraper that will actually extract the data

Here’s the Scrapy spider code:

Plain text

Copy to clipboard

Open code in new window

EnlighterJS 3 Syntax Highlighter

class ProductSpider(CrawlSpider):

name = 'product'

start_urls = ['http://books.toscrape.com/catalogue/category/books/travel\_2/index.html'\]

rules = (

Rule(LinkExtractor(restrict_css='article.product_pod > h3 > a'), callback='populate_item'),

)

def populate_item(self, response):

item = ProductItem()

book_title = response.css('div.product_main > h1::text').get()

price_text = response.css('p.price_color::text').get()

stock_info = response.css('p.availability').get()

item = {

'title': book_title,

'price': self.clean_price(price_text),

'stock': self.clean_stock(stock_info)

}

yield item

def clean_price(self, price_text):

return Price.fromstring(price_text).amount_float

def clean_stock(self, stock_info):

return remove_tags(stock_info).strip()

class ProductSpider(CrawlSpider): name = 'product' start_urls = ['http://books.toscrape.com/catalogue/category/books/travel\_2/index.html'\] rules = ( Rule(LinkExtractor(restrict_css='article.product_pod > h3 > a'), callback='populate_item'), ) def populate_item(self, response): item = ProductItem() book_title = response.css('div.product_main > h1::text').get() price_text = response.css('p.price_color::text').get() stock_info = response.css('p.availability').get() item = { 'title': book_title, 'price': self.clean_price(price_text), 'stock': self.clean_stock(stock_info) } yield item def clean_price(self, price_text): return Price.fromstring(price_text).amount_float def clean_stock(self, stock_info): return remove_tags(stock_info).strip()

1class ProductSpider(CrawlSpider):
2	name = 'product'
3	start\_urls = \['http://books.toscrape.com/catalogue/category/books/travel\_2/index.html'\]
4	rules = (
5    		Rule(LinkExtractor(restrict\_css='article.product\_pod > h3 > a'), callback='populate\_item'),
6	)
7	def populate\_item(self, response):
8    	item = ProductItem()
9    	book\_title = response.css('div.product\_main > h1::text').get()
10    	price\_text = response.css('p.price\_color::text').get()
11    	stock\_info = response.css('p.availability').get()
12    	item = {
13        	'title': book\_title,
14        	'price': self.clean\_price(price\_text),
15        	'stock': self.clean\_stock(stock\_info)
16    	}
17    	yield item
18	def clean\_price(self, price\_text):
19    		return Price.fromstring(price\_text).amount\_float
20	def clean\_stock(self, stock\_info):
21    		return remove\_tags(stock\_info).strip()
Copy

So let’s assume this is the spider you currently have and it was working fine… delivering you precious data… for a while. Then you wanted to scale up and make more requests which ultimately led to blocks, low success rate, bad data quality, etc… 

The solution to overcome blocks and receive high-quality web data is proxies and how you use those proxies. Let’s see how you can integrate Smart Proxy Manager in this spider!

Scrapy + Smart Proxy Manager

The recommended way for integration is the official middleware. This is how you can install it:

Plain text

Copy to clipboard

Open code in new window

EnlighterJS 3 Syntax Highlighter

pip install scrapy-crawlera

pip install scrapy-crawlera

1pip install scrapy-crawlera
Copy

Then, add these settings in your Scrapy project file:

Plain text

Copy to clipboard

Open code in new window

EnlighterJS 3 Syntax Highlighter

DOWNLOADER_MIDDLEWARES = {'scrapy_crawlera.CrawleraMiddleware': 610}

CRAWLERA_ENABLED = True

CRAWLERA_APIKEY = ''

DOWNLOADER_MIDDLEWARES = {'scrapy_crawlera.CrawleraMiddleware': 610} CRAWLERA_ENABLED = True CRAWLERA_APIKEY = ''

1DOWNLOADER\_MIDDLEWARES = {'scrapy\_crawlera.CrawleraMiddleware': 610}
2CRAWLERA\_ENABLED = True
3CRAWLERA\_APIKEY = '<API key>'
Copy

Notice that in order to use Smart Proxy Manager, you need an API key. But don’t worry, we offer a 14-day free trial (max 10K requests during the trial) so you can get your API key fast and try it out to make sure it works for you.

Optionally, you can also set the proxy URL if you requested a custom instance of Smart Proxy Manager:

Plain text

Copy to clipboard

Open code in new window

EnlighterJS 3 Syntax Highlighter

CRAWLERA_URL = 'myinstance.zyte.com:8011'

Another way to set up Smart Proxy Manager is directly in the spider, like this:

class ProductSpider(CrawlSpider):

crawlera_enabled = True

crawlera_apikey = 'apikey'

CRAWLERA_URL = 'myinstance.zyte.com:8011' Another way to set up Smart Proxy Manager is directly in the spider, like this: class ProductSpider(CrawlSpider): crawlera_enabled = True crawlera_apikey = 'apikey'

1CRAWLERA\_URL = 'myinstance.zyte.com:8011'
2Another way to set up Smart Proxy Manager is directly in the spider, like this:
3class ProductSpider(CrawlSpider):
4	crawlera\_enabled = True
5	crawlera\_apikey = 'apikey'
Copy

Settings recommendations

To achieve higher crawl rates when using Smart Proxy Manager, we recommend disabling the Auto Throttle addon and increasing the maximum number of concurrent requests. You may also want to increase the download timeout. Here is a list of settings that achieve that purpose:

Plain text

Copy to clipboard

Open code in new window

EnlighterJS 3 Syntax Highlighter

CONCURRENT_REQUESTS = 32

CONCURRENT_REQUESTS_PER_DOMAIN = 32

AUTOTHROTTLE_ENABLED = False

DOWNLOAD_TIMEOUT = 600

CONCURRENT_REQUESTS = 32 CONCURRENT_REQUESTS_PER_DOMAIN = 32 AUTOTHROTTLE_ENABLED = False DOWNLOAD_TIMEOUT = 600

1CONCURRENT\_REQUESTS = 32
2CONCURRENT\_REQUESTS\_PER\_DOMAIN = 32
3AUTOTHROTTLE\_ENABLED = False
4DOWNLOAD\_TIMEOUT = 600
Copy

No more failed web scraping projects

Sign up for a Zyte Smart Proxy Manager account

This simple integration takes care of everything you need to scale up your Scrapy project with proxies.

If you are tired of blocks or managing different proxy providers, try Smart Proxy Manager .

smart proxy manager

automatic extraction

Try Zyte API

Build your first scraper in minutes

Free trial, no credit card. From a single request to production in an afternoon.

Get started
Handling Bans
J

John Campbell

More from this author

In this article

  • Getting started
  • Scrapy + Smart Proxy Manager
  • Settings recommendations
  • No more failed web scraping projects
  • Sign up for a Zyte Smart Proxy Manager account

Follow

Get the latest

Zyte and the data web in your inbox — or wherever you already are.

Subscribe

Or follow elsewhere

Continue reading

How an analytics platform solved a ‘hard-to-scrape’ site using Zyte API
Handling Bans

How an analytics platform solved a ‘hard-to-scrape’ site using Zyte API

Behind the scenes of how Zyte API restored access to a major e-commerce site — automatically.

Mitch Holt·10 Mins·November 12, 2025
Unblockers vs Zyte API: What’s the Real Cost of Bans?
Handling Bans

Unblockers vs Zyte API: What’s the Real Cost of Bans?

When it comes to web scraping success, not all access tools are created equal. Here’s what it really costs to keep your scrapers running—and why the cheapest unblocker might be the most expensive choice you ever make.

Mitch Holt·10 Mins·November 12, 2025
Why your spiders keep getting banned, and how to fix it
Handling Bans

Why your spiders keep getting banned, and how to fix it

Stop wasting hours debugging bans. Learn what’s really blocking your scrapers and how to unblock sites automatically.

Mitch Holt·10 Mins·November 10, 2025

The Community · Newsletter

The best of Zyte and the data web, in your inbox.

One curated edition — new articles, product updates, and the stories shaping the data web. No noise.

G2.com

Capterra.com

Proxyway.com

EWDCI logoMost loved workplace certificateZyte rewardISO 27001 iconG2 rewardG2 rewardG2 reward

© Zyte Group Limited 2026