# Google Maps Scraper for Law Firms — Leads with Emails & Phones (`apitory/google-maps-law-firm-leads`) Actor

Law firm leads from Google Maps: prefilled practice-area pack (personal injury, divorce, criminal defense, immigration, family law and more across US cities) with public emails and phones from each firm's own website. A law firm lead scraper — $0.004/place, $0.10 only when a contact is found.

- **URL**: https://apify.com/apitory/google-maps-law-firm-leads.md
- **Developed by:** [Apitory.com](https://apify.com/apitory) (community)
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.00 / 1,000 places scraped

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Google Maps Scraper for Law Firms — Leads with Emails & Phones

Scrape Google Maps for law firms by practice area and city — with the emails and phone numbers firms publish on their own websites. Built for legal-marketing agencies, intake and CRM vendors, and legal-tech sales teams.

Pull **contactable leads for law firms** — general practice, personal injury, divorce, criminal defense, immigration, family law, estate planning and bankruptcy — straight from Google Maps, with the public contact details from each firm's own website attached.

You get one structured record per firm: **place data** (name, category, address, phone, website, rating, review count) **plus the contacts published on the firm's website** — emails, phone numbers and social profile links. The input comes prefilled with a practice-area pack covering Austin, Houston, Dallas, Chicago, New York, Denver, Seattle and Phoenix, and the proxy country is prefilled to **US**.

Built for **people who sell to law firms** — legal-marketing agencies, intake and CRM vendors, legal-services providers, legal-tech sales teams — and for anyone building a prospect list of firms with working contact details. Law firms publish contact details at high rates (they want clients to reach them), which is a good fit for this engine's contact-extraction design: in this engine's Madrid restaurant test (`restaurante en Madrid`, 15 places), **12 of 15 business websites yielded a public contact (80.0%) and 7 yielded an email (46.7%)**, and the same 80.0% contact rate was measured again in an Austin test.

### Quickstart

Default input — eight practice-area searches across eight cities; swap in your own practice areas and cities:

```json
{
  "searchTerms": [
    "law firm in Austin",
    "personal injury lawyer in Houston",
    "divorce lawyer in Dallas",
    "criminal defense attorney in Chicago",
    "immigration lawyer in New York",
    "family law attorney in Denver",
    "estate planning attorney in Seattle",
    "bankruptcy lawyer in Phoenix"
  ],
  "maxPlaces": 200,
  "extractContacts": true,
  "proxyCountry": "US"
}
```

One practice area + one city per term, written exactly as a client would type it into Maps. To cover several markets, duplicate the pack per city. To go deep on one practice area (say, every personal injury firm in a metro), keep a single term and raise `maxPlaces`. Firms are deduplicated by Google place ID across all terms, so overlapping terms never double-charge you.

**Search wording that works well on Maps:** `law firm`, `personal injury lawyer`, `divorce lawyer`, `criminal defense attorney`, `immigration lawyer`, `family law attorney`, `estate planning attorney`, `bankruptcy lawyer`, `employment lawyer`, `real estate attorney`, `tax attorney`, `workers compensation lawyer`.

### Use cases

- **Legal-marketing prospecting** — firms by practice area (personal injury, family, immigration, criminal defense) with working contacts.
- **Intake-tool selling** — firms publishing contact details at high rates are firms investing in being reached.
- **Prioritise by reputation** — rating and review count on every record.
- **Multi-city coverage** — the prefilled pack spans eight US metros; duplicate it per market.

### Pricing (pay per event)

| Event | Price | When it is charged |
|---|---|---|
| Actor start | $0.00005 per GB of memory | Once, when the run starts |
| **Place scraped** | **$0.004 / firm** | For every firm record in the dataset |
| **Lead scraped** | **$0.10 / lead** | **Only** when the firm's website yields at least one public email or phone (`contactFound: true`) |

No contact found → no lead charge. No website → no lead charge. You never pay the premium for an empty record.

### How it works

1. **Maps phase (browser).** For each search term, the Actor opens `google.com/maps/search/<term>` in Chromium through Apify Proxy (residential by default, exit IP pinned to the US unless you change `proxyCountry`), dismisses the Google consent dialog if shown, scrolls the results feed and harvests every result card. It then navigates to each place page directly and reads the detail panel. Places are deduplicated by Google place ID across all search terms.
2. **Contact phase (plain HTTP, no browser).** For every firm with a website, the Actor fetches the homepage plus up to 3 likely contact pages (discovered from the homepage's own links — `/contact`, `/about`, `/attorneys`, …) and extracts:

   - **emails** — `mailto:` links first, then a text pass with placeholder / image-filename / tracker-address filtering and light de-obfuscation (`name [at] domain [dot] com`);
   - **phones** — `tel:` links first, then a conservative text pass;
   - **social links** — Facebook, Instagram, LinkedIn, Twitter/X, YouTube profile URLs (share/intent/post URLs excluded).

   Websites shared by several offices (multi-location firms) are fetched once.

If Google serves its bot-detection "sorry" page for a search (rare through residential IPs), the Actor detects it, marks that term `BLOCKED_BY_GOOGLE` in the run metrics and finishes honestly with whatever it has — it does not crash or fabricate results.

### Inputs

| Input | Type | Default | Notes |
|---|---|---|---|
| `searchTerms` | string array | eight-term practice-area pack (Austin / Houston / Dallas / Chicago / New York / Denver / Seattle / Phoenix) | One practice area + one city per term, typed exactly as in Google Maps. |
| `maxPlaces` | integer | `200` | Cap on unique firms across all terms (max 1000). |
| `extractContacts` | boolean | `true` | Turn off for place data only (no lead events are charged). |
| `proxyGroup` | string | `RESIDENTIAL` | Apify Proxy group for the Maps browser phase. Residential is strongly recommended. |
| `proxyCountry` | string | `US` | Exit-IP country. Prefilled to the US; change only when retargeting the pack to another market. |
| `useApifyProxy` | boolean | `true` | Off only for local diagnostics. |

### Output — one record per law firm

| Field | Description |
|---|---|
| `name` | Firm name. |
| `category` | e.g. "Law firm", "Personal injury attorney" (renders in the exit IP's Google UI language — English with `proxyCountry: US`). |
| `address` | Address as shown on Maps. |
| `phone` | Phone as shown on Maps (website phones are in `_contact.phones`). Every record with a Maps listing phone is callable even without a website hit. |
| `website` | Website URL listed on Maps, or `null`. |
| `rating` / `reviewsCount` | Rating and review count from Maps — your prioritisation signal (a 4.9-star firm with 800 reviews is a different prospect from a 3.8 with 12). |
| `mapsUrl` | Link to the place on Google Maps. |
| `featureId` | Maps feature id (`0x…:0x…`). |
| `placeId` | Google `ChIJ…` place id — the deduplication key. |
| `searchTerm` | Which search produced this firm. |
| `contactFound` | `true` when the website yielded ≥ 1 email or phone (the **lead** condition). |
| `_contact` | `{ website, emails[], phones[], socialLinks[], pagesFetched[] }`, or `null` when the firm has no website. |

A run summary (firms found, websites visited, contact and email hit rates, per-search states such as `RENDERED` / `BLOCKED_BY_GOOGLE`) is stored in the key-value store record `metrics` and printed at the end of the run log.

#### Sample record (real output)

From the pre-publish test run (`law firm in Austin`, 10-place cap): **10 firms returned, all 10 with websites, 8 of them with a public contact found on their own website — an 80.0% contact rate (3 of the 10 with an email, 30.0%).** One of the 10, verbatim:

```json
{
  "name": "The Law Office of David Reed",
  "category": "Criminal justice attorney",
  "address": "608 W 12th St, Austin, TX 78701",
  "phone": "512) 853-0100",
  "website": "https://davidreedlaw.com/",
  "rating": 5,
  "reviewsCount": 301,
  "mapsUrl": "https://www.google.com/maps/place/The+Law+Office+of+David+Reed/data=!4m7!3m6!1s0x8644b547ee521297:0xcb8df608c5073a60!8m2!3d30.2759547!4d-97.7469301!16s%2Fg%2F11j0091kl4!19sChIJlxJS7ke1RIYRYDoHxQj2jcs?authuser=0&hl=en&g_ep=EgoyMDI2MTEyMy4wIJJjKgBIAVAD&rclk=1",
  "featureId": "0x8644b547ee521297:0xcb8df608c5073a60",
  "placeId": "ChIJlxJS7ke1RIYRYDoHxQj2jcs",
  "searchTerm": "law firm in Austin",
  "contactFound": true,
  "_contact": {
    "website": "https://davidreedlaw.com/",
    "emails": [
      "david@davidreedlaw.com"
    ],
    "phones": [
      "5128530100",
      "15122330791"
    ],
    "socialLinks": [
      "https://www.facebook.com/profile.php",
      "https://www.instagram.com/lawofficeofdavidreed"
    ],
    "pagesFetched": [
      "https://davidreedlaw.com/",
      "https://davidreedlaw.com/about/",
      "https://davidreedlaw.com/about/case-results/",
      "https://davidreedlaw.com/contact-us/"
    ]
  }
}
```

The email came from the firm's own site (homepage + `/about/` + `/contact-us/` fetched) — the contact-path discovery working end to end. The same 80.0% contact rate was measured independently in this engine's Madrid and Austin restaurant tests (12 of 15 each), so the figure is the pattern, not a fluke.

**Cost per lead, in plain numbers:** a 200-firm run costs $0.80 in place events. At the measured 80% contact rate (the Austin test run above; the Madrid and Austin restaurant tests measured the same), about 160 of those 200 would also carry the $0.10 lead charge ($16.00) — roughly $0.105 per usable lead, all-in. The lead charge applies only to firms whose website yields a public contact. Every run's summary reports its actual hit rate, so you can price your territory list from real numbers, not promises.

### Run it on a schedule

Firms open, merge and move constantly. Run this Actor on a monthly schedule per practice area and city, and diff the fresh list against the last one.

### FAQ

**Multi-location firms — do I get duplicates?** Two kinds, two answers. The *same office* surfaced by several of your search terms is deduplicated by Google place ID before anything is pushed or charged — you never pay twice for one office. *Different offices* of a firm are separate records on purpose: each office has its own phone, its own reviews and usually its own intake team, and for territory selling the office is the buying unit. If several offices share one firm website, that site is fetched once and its public contact may appear on each office's record — filter by website domain if you want one row per firm.

**Do you charge for duplicates?** No. Deduplication by place ID happens before pushing and charging.

**What if a firm has no website?** You get the place record (with the Maps phone, if listed) and pay only the $0.004 place event. For legal marketers, those records are a campaign of their own — a firm with no website is exactly who a web-design or intake pitch is for.

**Can I use it from the API / n8n / Make / Zapier?** Yes — like every Apify Actor it runs via the Apify API and the official integrations. Send the input JSON, read the default dataset when the run finishes. Run it on a schedule to rebuild a city's firm list monthly and diff against last month's for new openings and closures.

**Which countries are supported?** Anywhere Google Maps has listings. This pack is tuned for the US (practice-area terms, `proxyCountry: US`); for another market, change the cities in the terms and the `proxyCountry` code to match.

### Limitations (stated plainly)

- **DOM-based extraction.** Google Maps changes its markup regularly; the Actor leans on the most stable hooks available (`div[role="feed"]`, `data-item-id` attributes, the panel `h1`), but a field coming back `null` usually means a selector drifted, not that the data does not exist. Report it and it gets fixed.
- **Website fetching is plain HTTP.** A minority of sites block datacenter IPs or hide contacts behind JavaScript; those come back with empty `_contact` arrays and are **not** charged as leads.
- **Text-derived phones can include false positives.** `tel:`-link phones are reliable; treat text-only numbers as unverified.
- **Public data only.** The Actor collects contact details that law firms publish on Google Maps and on their own websites. It does not access private data. What you may do with a business's public contact details depends on your jurisdiction's marketing rules — use the output for research, enrichment and consented outreach, and take your own advice before running cold campaigns.

### Support

Questions, practice-area-pack requests, or a field that came back empty? Contact: **support@apitory.com** — issues are answered publicly in the Actor's Issues tab whenever possible.

***

*If this Actor saved you a morning of manual list-building, please leave a review — it helps other legal marketers find it.*

### Related Actors

- [Google Maps Email Extractor — Business Contacts & Leads](https://apify.com/apitory/google-maps-contacts) — the general engine — any niche, any city.
- [Google Maps Scraper for Real Estate — Leads with Contacts](https://apify.com/apitory/google-maps-real-estate-leads) — agencies, brokerages and property managers.
- [Google Maps Scraper for Dentists — Leads with Emails & Phones](https://apify.com/apitory/google-maps-dentist-leads) — dental practices, pre-tuned search pack.
- [Google Maps Scraper for Home Services — Leads with Contacts](https://apify.com/apitory/google-maps-home-services-leads) — plumbers, HVAC, roofers and other trades.

# Actor input Schema

## `extractContacts` (type: `boolean`):

For every law firm with a website, visit the website (homepage + up to 3 likely contact pages, including /contact) over plain HTTP and extract public emails, phones and social links into the record's \_contact object. This is what turns a place into a lead — turn off only if you want place data alone.

## `maxPlaces` (type: `integer`):

Stop after collecting this many unique law firms across all search terms. 200 covers roughly one practice area across a mid-size city, or the full pack across a smaller market.

## `proxyCountry` (type: `string`):

Two-letter country code for the Apify Proxy exit IP. Prefilled with 'US' — US law-firm searches work best from a US exit IP. Change it only if you retarget the pack to another market.

## `proxyGroup` (type: `string`):

Apify Proxy group used for the Google Maps browser phase. RESIDENTIAL is strongly recommended; datacenter IPs are served Google's 'sorry' page almost immediately.

## `searchTerms` (type: `array`):

Google Maps searches to run, exactly as a client would type them — one practice area + one city per term. The prefilled pack covers eight practice-area searches across eight US cities, framed for law firms. Replace the cities with your territory, duplicate the pack per city to cover several markets, or narrow it to a single practice area. Places are deduplicated across terms, so a firm surfaced by both 'law firm in Austin' and 'personal injury lawyer in Houston' appears once.

## `useApifyProxy` (type: `boolean`):

Turn off only for local/diagnostic runs without proxy. A direct run from a datacenter IP is expected to hit Google's 'sorry' page; the actor reports that state honestly instead of failing.

## Actor input object example

```json
{
  "extractContacts": true,
  "maxPlaces": 200,
  "proxyCountry": "US",
  "proxyGroup": "RESIDENTIAL",
  "searchTerms": [
    "law firm in Austin",
    "personal injury lawyer in Houston",
    "divorce lawyer in Dallas",
    "criminal defense attorney in Chicago",
    "immigration lawyer in New York",
    "family law attorney in Denver",
    "estate planning attorney in Seattle",
    "bankruptcy lawyer in Phoenix"
  ],
  "useApifyProxy": true
}
```

# Actor output Schema

## `dataset` (type: `string`):

One record per place (name, category, address, phone, website, rating, reviewsCount, mapsUrl, contactFound, and a \_contact object with the emails/phones/socials found on the business website), followed by one final record with \_meta=true summarizing the run (places found, contact hit rate, requests, bytes, elapsed time). Run metrics are also stored as a key-value store record named metrics.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "extractContacts": true,
    "maxPlaces": 200,
    "proxyCountry": "US",
    "proxyGroup": "RESIDENTIAL",
    "searchTerms": [
        "law firm in Austin",
        "personal injury lawyer in Houston",
        "divorce lawyer in Dallas",
        "criminal defense attorney in Chicago",
        "immigration lawyer in New York",
        "family law attorney in Denver",
        "estate planning attorney in Seattle",
        "bankruptcy lawyer in Phoenix"
    ],
    "useApifyProxy": true
};

// Run the Actor and wait for it to finish
const run = await client.actor("apitory/google-maps-law-firm-leads").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "extractContacts": True,
    "maxPlaces": 200,
    "proxyCountry": "US",
    "proxyGroup": "RESIDENTIAL",
    "searchTerms": [
        "law firm in Austin",
        "personal injury lawyer in Houston",
        "divorce lawyer in Dallas",
        "criminal defense attorney in Chicago",
        "immigration lawyer in New York",
        "family law attorney in Denver",
        "estate planning attorney in Seattle",
        "bankruptcy lawyer in Phoenix",
    ],
    "useApifyProxy": True,
}

# Run the Actor and wait for it to finish
run = client.actor("apitory/google-maps-law-firm-leads").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "extractContacts": true,
  "maxPlaces": 200,
  "proxyCountry": "US",
  "proxyGroup": "RESIDENTIAL",
  "searchTerms": [
    "law firm in Austin",
    "personal injury lawyer in Houston",
    "divorce lawyer in Dallas",
    "criminal defense attorney in Chicago",
    "immigration lawyer in New York",
    "family law attorney in Denver",
    "estate planning attorney in Seattle",
    "bankruptcy lawyer in Phoenix"
  ],
  "useApifyProxy": true
}' |
apify call apitory/google-maps-law-firm-leads --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,apitory/google-maps-law-firm-leads"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/sxxKXjBqld0GKyIFT/builds/tmPHsXYVzuSZ3OX1F/openapi.json
