Python automation script that checks website Google search ranking and page load speed for specified keywords without using proxies.
git clone https://github.com/dvbuiilds/python-seo-analyzer.gitPython SEO Analyzer is a free command-line tool that automates two critical SEO metrics: your website's Google search ranking for target keywords and page loading speed. The script scrapes Google SERPs using robobrowser to extract ranking data and measures page performance, outputting results in JSON format. It's designed for site owners and SEO professionals who need to monitor keyword rankings and performance without paid tools. Simply add your target keywords to a CSV file, specify your website URL and device type, and the script generates a comprehensive analysis. Note that checking large keyword volumes may trigger Google's rate limiting.
Install dependencies with pip install requirements.txt. Add keywords to keywords.csv file. Run python3 ./analyzer.py [website] [device] (e.g., python3 ./analyzer.py www.example.com desktop). Results are generated in JSON format showing ranking and page speed data.
Monitor keyword rankings for competitive analysis
Track page load speed performance over time
Automate SEO audits for multiple sites
Generate ranking reports for specific keywords
No install command available. Check the GitHub repository for manual installation instructions.
git clone https://github.com/dvbuiilds/python-seo-analyzerCopy the install command above and run it in your terminal.
Launch Claude Code, Cursor, or your preferred AI coding agent.
Use the prompt template or examples below to test the skill.
Adapt the skill to your specific use case and workflow.
Create a Python script that analyzes SEO metrics for a website. The script should include functions to measure page loading time and check Google rankings for specific keywords. The output should be formatted in a clear, readable way. Focus on [COMPANY] in the [INDUSTRY] sector, using [KEYWORDS] as the target keywords for ranking analysis.
```python
# SEO Analyzer Script
import requests
import time
from bs4 import BeautifulSoup
# Function to measure page loading time
def measure_page_load_time(url):
start_time = time.time()
response = requests.get(url)
end_time = time.time()
load_time = end_time - start_time
return load_time
# Function to check Google rankings for keywords
def check_google_ranking(keywords, url):
rankings = {}
for keyword in keywords:
search_url = f"https://www.google.com/search?q={keyword}"
response = requests.get(search_url, headers={'User-Agent': 'Mozilla/5.0'})
soup = BeautifulSoup(response.text, 'html.parser')
results = soup.find_all('div', class_='tF2Cxc')
for i, result in enumerate(results, 1):
if url in result.text:
rankings[keyword] = i
break
return rankings
# Example usage
company_url = "https://www.exampletech.com"
keywords = ["cloud computing", "AI solutions", "data analytics"]
load_time = measure_page_load_time(company_url)
rankings = check_google_ranking(keywords, company_url)
print(f"Page Load Time: {load_time:.2f} seconds")
print("Google Rankings:")
for keyword, rank in rankings.items():
print(f"{keyword}: Rank #{rank}")
```Take a free 3-minute scan and get personalized AI skill recommendations.
Take free scan