EhsanSafir / Google-Reviews-Extractor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Google Reviews Extractor

This Python repository contains a basic web scraper using Selenium to extract Google reviews from a specified URL. The scraper exports the extracted data to an Excel file.

Installation

Install the required dependencies:

    pip install -r requirements.txt

Usage

Below is an example of how to use the Google Review Scraper in your own Python script.

    from extractor import GoogleReviewExtractor

# Specify the Google search URL for the business or location
url = '.....'
# Create an instance of GoogleReviewExtractor
scrapper = GoogleReviewExtractor(url)
# Run the scraper to extract reviews and save to Excel
scrapper.start_scrapping()

Dependencies

  • selenium==4.15.2
  • openpyxl==3.1.2

Configuration

  • review_extractor.py: Defines the web scraper class (GoogleReviewExtractor) and contains the necessary Selenium selectors.
  • example1.py: Example usage of the scraper on a specific Google search URL.
  • requirements.txt: Lists the required Python packages.

Notes

About


Languages

Language:Python 100.0%