Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Farfetch.com Search Listings Scraper and Product Details Page Scraper. Scrapers effectively handle JS rendering and CAPTCHA using Crawlbase Crawling API.

NotificationsYou must be signed in to change notification settings

ScraperHub/farfetch-scrapers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

crawling-api-cta

farfetch-scrapers

Description

This repository contains Python-based scrapers for extracting product data fromFarfetch. These scrapers use theCrawlbase Crawling API to bypass JavaScript rendering, CAPTCHA challenges, and anti-bot protections, enabling smooth data extraction.

➡ Read the full bloghere to learn more.

Scrapers Overview

Farfetch Search Results Scraper

The Farfetch Search Results Scraper (farfetch_serp_scraper.py) extracts product details from search listings, including:

  • Brand Name
  • Product Description
  • Price
  • Discount (if available)
  • Product URL

It supports pagination, allowing multiple search results pages to be scraped. The extracted data is saved in a CSV file.

Farfetch Product Page Scraper

The Farfetch Product Page Scraper (farfetch_product_page_scraper.py) extracts product details from individual product pages, including:

  • Product Blurb
  • Brand Name
  • Price
  • Full Product Description

This scraper takes product URLs from the search listings scraper and extracts product details, saving the data in a CSV file.

Environment Setup

Ensure that Python is installed on your system. Check the version using:

# Use python3 if you're on Linux/macOSpython --version

Install the required dependencies:

pip install crawlbase beautifulsoup4
  • Crawlbase – Handles JavaScript rendering and bypasses bot protections.
  • BeautifulSoup – Parses and extracts structured data from HTML.

Running the Scrapers

1. Get Your Crawlbase Access Token

  • Sign up for Crawlbasehere to get an API token.
  • Use theJS token for Farfetch scraping, as the site relies on JavaScript-rendered content.

2. Run the Search Listings Scraper

This scraper extracts product listings and saves them infarfetch_listings.csv:

# Use python3 if required (for Linux/macOS)python farfetch_serp_scraper.py

3. Run the Product Page Scraper

Once you have the search results, extract detailed product information using:

python farfetch_product_page_scraper.py

This will fetch and save product details infarfetch_product_details.csv.

To-Do List

  • Add more product details (e.g., sizes, materials, colors).
  • Support JSON output in addition to CSV.
  • Improve pagination to handle dynamic page numbers.
  • Add better error handling and retries for failed requests.

Features

  • Bypasses anti-bot protections using Crawlbase.
  • Handles JavaScript-rendered content efficiently.
  • Extracts structured product data in CSV format for easy analysis.
  • Supports pagination to scrape multiple search result pages.

About

Farfetch.com Search Listings Scraper and Product Details Page Scraper. Scrapers effectively handle JS rendering and CAPTCHA using Crawlbase Crawling API.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp