# Grubhub Restaurant Scraper — Menus, Ratings & Fees (`haketa/grubhub-scraper`) Actor

Scrape Grubhub restaurants by location: name, cuisines, rating & reviews, price level, delivery & service fees, delivery time, distance, phone and address. Enter ZIP codes, addresses or coordinates.

- **URL**: https://apify.com/haketa/grubhub-scraper.md
- **Developed by:** [Haketa](https://apify.com/haketa) (community)
- **Categories:** E-commerce, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-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

## Grubhub Restaurant Scraper — Ratings, Fees & Cuisines by Location

> **Extract Grubhub restaurants for any US location: name, cuisines, star rating & review count, price level, delivery & service fees, delivery-time estimate, distance, phone and address.** Enter ZIP codes, addresses or coordinates and get clean, structured JSON/CSV/Excel in seconds. Built for food-delivery analysts, restaurant lead-gen, competitive pricing and market research.

[![Restaurants](https://img.shields.io/badge/Grubhub-Restaurants-f63440)]()
[![Ratings & Fees](https://img.shields.io/badge/Ratings%20%2B%20Fees%20%2B%20ETA-blue)]()
[![By Location](https://img.shields.io/badge/Any-US%20Location-1aa06d)]()
[![Export](https://img.shields.io/badge/Export-JSON%20%2F%20CSV%20%2F%20Excel-fb8500)]()

***

### What This Actor Does

**Grubhub** is one of the largest US food-delivery marketplaces. This Actor returns every restaurant available at a location as a clean row:

- **Restaurant** — name, cuisines, star rating & review count, price level ($–$$$$)
- **Delivery economics** — delivery fee, service fee, delivery minimum, delivery-time estimate, distance
- **Details** — address (street/city/state/ZIP), phone, open status, pickup/delivery availability, coupons
- **Links** — the direct Grubhub restaurant URL

Enter one or many locations (ZIP, address, city or `lat,lng`) and it paginates through the full restaurant list at each.

***

### Why Use This

- **Location-based market view.** See the entire restaurant supply, pricing and delivery economics for any US ZIP or address — exactly what a customer would see.
- **Competitive & pricing intelligence.** Compare delivery fees, minimums, price levels and ratings across restaurants and neighborhoods.
- **Restaurant lead lists.** Name, phone, address, cuisines and ratings make a targeted lead source for restaurant-tech, suppliers and delivery services.
- **Fast and structured.** Reads Grubhub's own API directly — every field typed and clean, no brittle HTML scraping.

***

### Quick Start

#### Run it in the console (no code)

1. Enter one or more **Locations** — ZIP codes, addresses, cities, or `lat,lng` (e.g. `10001`, `New York, NY`, `40.7484,-73.9857`).
2. Optionally set a **Search keyword** (e.g. `pizza`, `sushi`) and choose **delivery** or **pickup**.
3. Click **Start**, then export as **JSON, CSV, Excel or HTML**, or push to Google Sheets, a webhook or a database.

> The proxy is preconfigured (US residential) since Grubhub requires it — just enter a location and run.

#### Run it via API (Python)

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_APIFY_TOKEN")

run_input = {
    "locations": ["10001", "90012"],
    "searchText": "pizza",
    "maxItemsPerLocation": 200,
}

run = client.actor("YOUR_USERNAME/grubhub-scraper").call(run_input=run_input)

for r in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(r["name"], "·", r["rating"], "·", r["deliveryFee"], "·", r["cuisines"])
```

#### Compare delivery fees in a ZIP (Python)

```python
run = client.actor("YOUR_USERNAME/grubhub-scraper").call(run_input={
    "locations": ["60601"],
    "maxItemsPerLocation": 300,
})
rows = list(client.dataset(run["defaultDatasetId"]).iterate_items())
free = [r for r in rows if (r.get("deliveryFee") or 0) == 0]
print(len(free), "of", len(rows), "restaurants offer free delivery")
```

#### Build a restaurant lead list (Node.js)

```javascript
import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_APIFY_TOKEN' });

const run = await client.actor('YOUR_USERNAME/grubhub-scraper').call({
    locations: ['Austin, TX'],
    maxItemsPerLocation: 300,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
const leads = items.filter(r => r.phone).map(r => ({
    name: r.name, phone: r.phone, cuisines: r.cuisines, rating: r.rating, address: `${r.street}, ${r.city}`,
}));
console.log(leads.length, 'restaurant leads');
```

***

### Input Parameters

| Field | Type | Description |
|---|---|---|
| `locations` | array | ZIP codes, addresses, cities, or `lat,lng`. Each is searched separately. |
| `searchText` | string | Optional keyword (cuisine or restaurant). Empty = all restaurants. |
| `orderMethod` | string | `delivery` or `pickup`. |
| `maxItemsPerLocation` | integer | Max restaurants per location. Default `200`. |
| `maxItems` | integer | Optional hard cap on total restaurants. `0` = no limit. |
| `proxyConfiguration` | object | Preconfigured to US residential (required by Grubhub). |

***

### Output

Each restaurant is one record:

```json
{
  "restaurantId": "8673688",
  "name": "Pura Vida Miami",
  "cuisines": ["Breakfast", "Bowls", "Sandwiches", "Wraps"],
  "rating": 5, "ratingCount": 770,
  "priceRating": 2,
  "street": "…", "city": "New York", "region": "NY", "postalCode": "10011",
  "distanceMiles": 0.34,
  "deliveryFee": 0, "serviceFee": null, "deliveryMinimum": 0,
  "deliveryTimeEstimate": 16,
  "pickup": true, "delivery": true, "open": true,
  "phone": "3055354142",
  "couponsAvailable": true,
  "url": "https://www.grubhub.com/restaurant/8673688",
  "searchLocation": "New York, NY"
}
```

***

### Use Cases

#### 1. Food-delivery market research

Map the full restaurant supply, cuisine mix, ratings and delivery economics for any ZIP or city — and compare neighborhoods or markets.

#### 2. Competitive & pricing intelligence

Benchmark delivery fees, service fees, minimums, price levels and ETAs across restaurants and areas to inform pricing and positioning.

#### 3. Restaurant lead generation

Every restaurant carries name, phone, address, cuisines and rating — a targeted lead source for restaurant tech, POS, suppliers and delivery services.

#### 4. Ratings & reputation analysis

Aggregate ratings and review counts by cuisine, price level and location to spot top performers and gaps.

#### 5. Site selection & expansion

Assess restaurant density, cuisine saturation and delivery economics before opening or expanding into an area.

***

### Tips

- **Locations** can be ZIP codes, full addresses, city names or `lat,lng`. Coordinates are the most precise; addresses/ZIPs are geocoded automatically.
- **`searchText`** narrows to a cuisine or restaurant (e.g. `vegan`, `mcdonalds`) — efficient for targeted pulls.
- **`orderMethod: pickup`** returns pickup availability instead of delivery.
- **Multiple locations** in one run map a whole city or region; each row carries its `searchLocation`.
- **Schedule it** with Apify Schedules to track fees, ratings and new restaurants over time.

***

### Frequently Asked Questions

**Do I need a Grubhub account?**
No. The Actor reads publicly available restaurant listing data — no login required.

**Why is a proxy required?**
Grubhub is protected by anti-bot; a US residential proxy is preconfigured so it works out of the box.

**How do I specify a location?**
Enter a ZIP, address, city, or `lat,lng`. Non-coordinate inputs are geocoded automatically.

**Does it include menus?**
It returns each restaurant's core data (ratings, fees, cuisines, contact). Full menus are per-restaurant and can be added on request.

**What export formats are supported?**
JSON, CSV, Excel, HTML, or via API — plus Google Sheets, webhooks, Make and Zapier.

***

### Legal & Responsible Use

This Actor collects only publicly available restaurant listing information for research and business use. You are responsible for how you use the data. Please:

- Respect Grubhub's Terms of Service and robots directives.
- Comply with applicable data-protection laws when handling any personal data.
- Do not use the data for spam, harassment, or any unlawful purpose.
- Use reasonable request volumes and scheduling.

This project is an independent tool and is not affiliated with, endorsed by, or sponsored by Grubhub.

# Actor input Schema

## `locations` (type: `array`):

ZIP codes, addresses, cities, or "lat,lng" coordinates (e.g. "10001", "New York, NY", "40.7484,-73.9857"). Each is searched separately.

## `searchText` (type: `string`):

Optional keyword to filter restaurants or cuisines (e.g. "pizza", "sushi", "vegan"). Leave empty for all restaurants.

## `orderMethod` (type: `string`):

delivery or pickup.

## `maxItemsPerLocation` (type: `integer`):

Maximum restaurants to collect per location (paginates as needed).

## `maxItems` (type: `integer`):

Optional hard cap on total restaurants across all locations. 0 = no limit.

## `proxyConfiguration` (type: `object`):

Grubhub requires a US residential proxy (datacenter IPs are blocked by anti-bot) — residential is enabled by default.

## Actor input object example

```json
{
  "locations": [
    "New York, NY"
  ],
  "orderMethod": "delivery",
  "maxItemsPerLocation": 60,
  "maxItems": 0,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "US"
  }
}
```

# Actor output Schema

## `restaurantId` (type: `string`):

Grubhub restaurant ID

## `name` (type: `string`):

Restaurant name

## `cuisines` (type: `string`):

Cuisine tags

## `rating` (type: `string`):

Star rating

## `ratingCount` (type: `string`):

Number of ratings

## `priceRating` (type: `string`):

Price level 1-4 ($-$$$$)

## `street` (type: `string`):

Street address

## `city` (type: `string`):

City

## `region` (type: `string`):

State/region

## `postalCode` (type: `string`):

Postal code

## `distanceMiles` (type: `string`):

Distance from location

## `deliveryFee` (type: `string`):

Delivery fee

## `serviceFee` (type: `string`):

Service fee

## `deliveryMinimum` (type: `string`):

Delivery minimum

## `deliveryTimeEstimate` (type: `string`):

Delivery time estimate

## `pickup` (type: `string`):

Offers pickup

## `delivery` (type: `string`):

Offers delivery

## `open` (type: `string`):

Currently open

## `phone` (type: `string`):

Phone number

## `couponsAvailable` (type: `string`):

Coupons available

## `url` (type: `string`):

Restaurant URL

## `searchLocation` (type: `string`):

Input location searched

## `scrapedAt` (type: `string`):

ISO timestamp

# 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 = {
    "locations": [
        "New York, NY"
    ],
    "orderMethod": "delivery",
    "maxItemsPerLocation": 60,
    "maxItems": 0,
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ],
        "apifyProxyCountry": "US"
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("haketa/grubhub-scraper").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 = {
    "locations": ["New York, NY"],
    "orderMethod": "delivery",
    "maxItemsPerLocation": 60,
    "maxItems": 0,
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
        "apifyProxyCountry": "US",
    },
}

# Run the Actor and wait for it to finish
run = client.actor("haketa/grubhub-scraper").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 '{
  "locations": [
    "New York, NY"
  ],
  "orderMethod": "delivery",
  "maxItemsPerLocation": 60,
  "maxItems": 0,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "US"
  }
}' |
apify call haketa/grubhub-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,haketa/grubhub-scraper"
        }
    }
}
```

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/gXSwgWI6e8wsJJeuf/builds/Wy2CPlMwQ4cyb1k41/openapi.json
