How I Built a Lead Gen Tool with Google Maps and Web Scraping
Draft Disclaimer: Please note that this article is currently in draft form and may undergo revisions before final publication. The content, including information, opinions, and recommendations, is subject to change and may not represent the final version. We appreciate your understanding and patience as we work to refine and improve the quality of this article. Your feedback is valuable in shaping the final release.
Language Mismatch Disclaimer: Please be aware that the language of this article may not match the language settings of your browser or device.
Do you want to read articles in English instead ?
TL;DR
I built a lead gen tool that pulls companies from Google Maps, scrapes their websites for emails, phone numbers, and employee data, checks them against my CRM, and uses Google Custom Search to fill gaps. Headless Chrome handles JavaScript-rendered sites. Total cost: under $5 per 1,000 leads.
The Problem with Finding Leads Manually
Finding potential customers for a B2B SaaS is tedious. You search Google Maps, open company websites one by one, copy emails and phone numbers into a spreadsheet, and try to figure out who the right contact person is. It takes hours and the data goes stale fast.
I needed a better system. Something that could pull company data from Google Maps, enrich it with real information from their website, and check it against my existing CRM to avoid duplicating work. So I built one.
Sourcing Companies from Google Maps
The first step is sourcing. Google Maps is one of the best free databases for finding local businesses. You can search by industry and location, and you get names, addresses, phone numbers, and website URLs.
I built a scraper that takes a search query and a location, then pulls every matching business from Google Maps. For each result, I store the company name, address, phone number, website URL, and Google Maps rating. That gives me a raw list of potential leads.
The key here is volume. A single search for "logistics companies in Dakar" can return hundreds of results. That is hundreds of leads I did not have to find manually.
Enriching from the Company Website
A Google Maps listing only gives you surface-level data. To qualify a lead, I need more. That is where website enrichment comes in.
For each company that has a website, I visit the site and extract:
- Emails: Any email addresses listed on the site, usually on contact or about pages
- Phone numbers: Additional numbers beyond what Google Maps provides
- City and country: Parsed from the website footer or contact section to confirm or correct the Google Maps location
- Links: All links on the main page, parsed to map out the site structure and find relevant subpages
I also check for careers or team pages. If a company lists employees with titles related to fleet management, logistics, or operations, those are high-value contacts. A fleet manager is far more likely to buy GPS tracking than a generic "info@" email address.
Checking Against Existing Data
Before adding a lead to my pipeline, I check it against my CRM and database. Does this company already have an account? Are they part of a team with active GPS devices? Have I contacted them before?
This status check prevents wasted outreach. There is no point pitching a company that is already a customer, or one that churned last month and needs a different approach.
The enrichment step tags each lead with a status: new, existing customer, active GPS user, or previously contacted. That way, when I look at my lead list, I know exactly where each company stands.
What Is Next: Google Custom Search for Structured Results
Some company websites are thin. No emails, no team page, barely any content. Website scraping alone will not be enough for those.
The next step I am considering is Google Custom Search API. The idea is to search for the company name plus keywords like "fleet manager," "logistics director," or "contact email." The API returns structured results that could fill the gaps when a company website gives me nothing useful.
The pricing makes it worth trying: 100 free queries per day, $5 per 1,000 after that. For lead generation, that is almost nothing compared to the value of a single qualified lead. I have not built this part yet, but it is the logical next layer of enrichment.
Handling Client-Side Rendering
Here is a problem most scrapers run into: modern websites render content with JavaScript. If you just fetch the HTML, you get an empty shell. No emails, no phone numbers, no team members. The actual content loads after JavaScript executes.
I handle this with headless Chrome. Instead of fetching raw HTML, I spin up a headless browser that renders the full page, waits for JavaScript to execute, and then extracts the data. It is slower than a simple HTTP request, but it works on every website, even single-page apps built with React or Vue.
The tradeoff is speed vs. completeness. For simple static sites, a basic HTTP fetch is fine. For anything modern, headless Chrome is the only reliable option. I detect which approach to use based on the initial response. If the HTML is mostly empty, I retry with headless Chrome.
The Full Pipeline
The complete flow looks like this:
- Search Google Maps for companies in a target industry and location
- For each company, visit the website and extract emails, phones, links, and employee data
- Check each company against the CRM for existing relationships
- For thin websites, run a Google Custom Search query to fill gaps
- Store everything in a structured database with status tags
The result is a clean, enriched list of leads with contact information, employee names, and CRM status. No manual research. No spreadsheets. Just a pipeline that runs and produces qualified leads.
Why This Matters for Bootstrapped SaaS
Paid lead gen tools cost $50 to $200 per month, and they still require manual work. Building my own tool cost me a few days of development and $5 per 1,000 Google searches. For a bootstrapped SaaS, that is a meaningful difference.
More importantly, I own the data and the process. I can customize the enrichment logic for my exact use case. I can prioritize companies with fleet managers. I can filter by country or city. I can integrate directly with my CRM.
If you are building a B2B SaaS, lead generation is not optional. The question is whether you pay someone else to do it poorly or build something that fits your business exactly. I chose to build.