Skip to main content

Scraping and parsing amazon

Project description


Scraping and parsing amazon

To install: pip install an

Amazon Scraping Library


This Python library is designed for scraping and parsing data from Amazon product pages. It offers functionalities to extract various information like sales ranks, product reviews, and product titles from Amazon's different regional websites.


This library is not a standalone package and should be incorporated directly into your existing Python project. Copy the code into your project's directory.


  • pandas
  • numpy
  • requests
  • BeautifulSoup
  • pymongo
  • matplotlib

Ensure these dependencies are installed in your environment.


Extracting Sales Rank

The library can extract sales ranks of products from Amazon. Here's an example of how to get the sales rank of a product:

country = ''  # Change to desired Amazon region
sales_rank = Amazon.get_sales_rank(asin=asin, country=country)

Parsing Product Title

To parse and get the product title from an Amazon product page:

html_content = Amazon.slurp(what='product_page', asin=asin, country=country)
title = Amazon.parse_product_title(html_content)

Getting Number of Reviews

To retrieve the number of customer reviews for a product:

number_of_reviews = Amazon.get_number_of_reviews(asin=asin, country=country)


Contributions to this library are welcome. Please send pull requests with improvements or bug fixes.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

an-0.0.7.tar.gz (10.4 kB view hashes)

Uploaded Source

Built Distribution

an-0.0.7-py3-none-any.whl (10.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page