Extract Business Leads from Google Maps Automatically ๐
A professional automation tool to scrape business data (name, phone, website, emails) from Google Maps with a beautiful web interface.
Problem: Manual data collection = time-consuming, error-prone
Solution: This tool automatically extracts 100+ business leads from Google Maps in minutes
โ
Business Development - Find prospects automatically
โ
Sales Lead Generation - Build targeted contact lists
โ
Market Research - Analyze competitor presence
โ
Real Estate - Find property-related businesses
โ
Franchise Research - Compare business density by area
pip install -r requirements.txt
playwright install chromiumpython app.pyhttp://localhost:5000
Then:
- Enter business type (e.g., "Restaurant", "Plumber", "Cafe")
- Enter city (e.g., "New York", "Mumbai", "London")
- Click "Start Scraping"
- Download CSV or JSON
That's it! โ
Run the test suite:
python test_setup.pyOutput:
โ
All tests passed! Ready to run.
| Field | Example |
|---|---|
| Business Name | Starbucks Coffee |
| Address | 123 Main St, New York, NY 10001 |
| Phone | (212) 555-0123 |
| Website | https://starbucks.com |
| Emails | manager@starbucks.com |
name,address,phone,website,emails
Starbucks,"123 Main St, New York","(212) 555-0123","https://starbucks.com","manager@starbucks.com"
Blue Bottle Coffee,"456 Park Ave, New York","(212) 555-0456","https://bluebottlecoffee.com","contact@bluebottlecoffee.com"
Joe Coffee Company,"789 Broadway, New York","(212) 555-0789","https://joecoffee.com","N/A"
[
{
"name": "Starbucks",
"address": "123 Main St, New York",
"phone": "(212) 555-0123",
"website": "https://starbucks.com",
"emails": "manager@starbucks.com"
}
]Keyword: Pizza
City: New York
Max Results: Leave empty (get all)
Timeout: 15 minutes
Skip Emails: OFF (get emails too)
Result: 150+ pizza restaurants with phone & email
Keyword: Restaurant
City: Los Angeles
Max Results: 5
Timeout: 5 minutes
Skip Emails: ON (faster)
Result: Quick list in ~3 minutes
Keyword: Digital Marketing Agency
City: San Francisco
Max Results: 100
Timeout: 20 minutes
Skip Emails: OFF
Result: 100 agencies with contact info
โ
No coding needed - just click and fill
โ
Real-time progress tracking
โ
Beautiful dashboard with stats
โ
Mobile responsive
โ
Automatic retry on errors
โ
Smart rate limiting (won't get banned)
โ
Email validation (no false positives)
โ
Duplicate removal
โ
CSV format (for Excel/Sheets)
โ
JSON format (for APIs)
โ
Detailed logs for debugging
โ
Resume capability (don't lose progress)
| Setting | What It Does |
|---|---|
| Keyword | Type of business (e.g., "Cafe", "Gym", "Lawyer") |
| City | Location to search (e.g., "New York", "Mumbai") |
| Max Results | Stop after N businesses (leave empty for all) |
| Timeout | Max time to run (5-30 minutes) |
| Skip Emails | Faster if you don't need emails |
| Headless Mode | Faster (no visible browser) |
| Scenario | Results | Time |
|---|---|---|
| Small city search | 30-50 | 3-5 min |
| Medium city | 100-150 | 10-15 min |
| Large city (no emails) | 200+ | 15-20 min |
| Large city (with emails) | 100-150 | 20-30 min |
- Search โ Opens Google Maps & searches your keyword
- Scroll โ Loads all available results (not just first page)
- Extract โ Gets name, phone, website, address
- Email Mine โ Visits websites & extracts emails (optional)
- Deduplicate โ Removes duplicates & validates data
- Export โ Saves as CSV & JSON
See detailed workflow: HOW_IT_WORKS.md
output/
โโโ businesses.csv โ Open in Excel
โโโ businesses.json โ Use in APIs
logs/
โโโ scraper_*.log โ Debugging info
If you prefer terminal:
# Basic search
python maps_scraper.py --keyword "Restaurant" --city "New York"
# With limits
python maps_scraper.py --keyword "Cafe" --city "London" --max-results 50
# Fast mode (no emails)
python maps_scraper.py --keyword "Gym" --city "Paris" --no-emails --headless
# Resume from checkpoint
python maps_scraper.py --keyword "Plumber" --city "Mumbai" --resume --timeout 900- Start with 10 results โ Test before big scrape
- Use headless mode โ 2-3x faster (default: ON)
- Skip emails first โ Get all businesses, extract emails later
- Specific keywords work better โ "Italian Restaurant" > "Restaurant"
- Run at off-hours โ Less chance of getting blocked
- โ Legal for personal/business use
- โ Respects rate limits (built-in delays)
โ ๏ธ Don't scrape too aggressively (may get IP blocked)- ๐ก Consider proxies for large-scale scraping
| Problem | Solution |
|---|---|
| No results found | Try simpler keyword or different city |
| Very slow | Enable "Skip Emails", reduce timeout |
| Getting blocked | Wait 2-3 hours, try different city |
| Crashes midway | Use "Resume" feature to continue |
See HOW_IT_WORKS.md for complete guide.
- Python 3.8+
- Flask 3.0+
- Playwright (Chromium browser)
git clone https://github.com/parnika-sa/maps.git
cd mapspython -m venv venv
venv\Scripts\activatepip install -r requirements.txt
playwright install chromiumpython test_setup.pypython app.pyhttp://localhost:5000
Done! ๐
Want to improve this? Check CONTRIBUTING.md for guidelines.
MIT License - See LICENSE for details
Free to use for personal & commercial projects
Questions? Check HOW_IT_WORKS.md for detailed documentation.
Your support motivates me to improve this tool ๐
Made with โค๏ธ by Ankit Maurya