A well-structured README for your SERP Results using Bright Data project.
# SERP Results using Bright Data π
**Fetch search engine results asynchronously using Bright Data API and store them in an Excel file.**
This script automates Google searches, excludes specified domains, and extracts the top two organic search results.
---
## π Features
β
**Asynchronous execution** for fast query processing
β
**Exclusion filters** to remove unwanted domains
β
**Automated backup & recovery** for large datasets
β
**Excel & CSV support** for easy data handling
β
**Logs & status updates** for real-time progress
---
## π¦ Installation
### 1οΈβ£ Clone this repository:
```sh
git clone https://github.com/DataDiggerJay/SERP-results-using-BrightData.git
cd SERP-results-using-BrightDatapip install -r requirements.txt-
Sign Up on Bright Data
- Go to Bright Data and create an account.
-
Create a New Zone
- Navigate to the Bright Data dashboard.
- Go to Zones and create a new SERP API Zone.
-
Generate an API Key
- In the API settings, generate a new API key.
- Keep this key private.
-
Update
script.py- Replace
"YOUR_BRIGHT_DATA_API_KEY"inscript.pywith your actual API key.
- Replace
- Create an Excel file (
queries.xlsx) - Add a column named
"Search Query"containing search terms
python script.py- Results are saved back to the Excel file.
- Backup is stored in
backup.csvto prevent data loss.
To prevent fetching results from certain websites, modify the EXCLUDE_SITES list in script.py.
Example:
EXCLUDE_SITES = [".medium.com", ".blogger.com", ".blogspot.com", "youtube.com"]Input (queries.xlsx):
| Search Query |
|---|
| Best Python courses |
| AI tools 2024 |
Output (queries.xlsx after running the script):
| Search Query | Result 1 | Result 2 |
|---|---|---|
| Best Python courses | https://realpython.com | https://learnpython.org |
| AI tools 2024 | https://towardsdatascience.com | https://ai.googleblog.com |
πΉ Issue: API requests fail
π Check if your API key is correct and Zone settings allow requests.
πΉ Issue: Results are empty
π Ensure Google SERP API Zone is active & API usage is not limited.
πΉ Issue: queries.xlsx not found
π Make sure the Excel file exists and is correctly named.
Feel free to fork this repository and submit pull requests! π
This project is licensed under the MIT License.
For questions or support, reach out on GitHub or open an issue. π
---
### π₯ What This README Covers:
β
**Project Overview**
β
**Installation Guide**
β
**How to Get an API Key**
β
**How to Use the Script**
β
**Example Output**
β
**Troubleshooting & FAQs**
β
**Contributing Guidelines**
β
**License & Contact Info**