# Yellow Pages Canada Scraper (Business Listing)

Scrape business listings from Yellow Pages Canada by keyword and location. Extract company names, categories, addresses, phone numbers, and listing URLs for research or lead building.

- Template page: [https://www.octoparse.com/template/yellow-pages-canada-scraper-product-listing](https://www.octoparse.com/template/yellow-pages-canada-scraper-product-listing)
- Categories: Directories, Lead Generation
- Status: `PUBLISHED`
- Run mode: `BOTH`

## Pricing

Free.

## What is an Octoparse template?

An Octoparse template is a ready-to-use scraping workflow with predefined inputs and structured outputs. Use the exact parameter keys below; do not invent parameters.

## Overview

This ready-to-use template collects structured data from listing pages.

## Output

The current workflow extracts 12 fields, including `Address`, `Business_name`, `Current_status`, `Description`, `Detail_URL`, `Editor_s_pick`, `Keyword`, `Location`, `Rating`, `Rating_count`, `Telephone`, `Website`.

## Use Cases

- Use structured results for research, comparison, and monitoring.
- Collect rows without building the extraction workflow from scratch.
- Combine results with other templates for downstream enrichment.
- Review a representative result before starting a large batch.

## Why Octoparse

- **No coding required:** complete Keyword and location (up to 20) and start the template in local or cloud mode.
- **Flexible export:** review and export results as CSV, Excel, or JSON.

## Input

### Keyword and location (up to 20)

Required. Enter a keyword and a location separated by a semicolon (no spaces). Each line represents one search query. Constraints: minItems=1; maxItems=20; items.minLength=1; items.maxLength=5000.

## How to Use

# Yellow Pages Canada Scraper Guide

## Input Parameters

| Parameter | Required | Description | Example |
|-----------|----------|-------------|---------|
| `Keyword;Location` | Yes | Enter a keyword and a location separated by a semicolon (no spaces). Each line represents one search query. | `restaurant;Toronto`  
`plumber;Vancouver` |

## Step-by-Step

1. **Start the template**  
   Click **"Try it!"** or **"Start"** to load the Superpages Scraper.

2. **Enter your scraping parameters**  
   Fill in the `Keyword;Location` field. Use the format `keyword;location` with a semicolon and no spaces. One query per line.

3. **Run the scraper**  
   - Click **"Start"** and select a run mode. (Greyed-out modes are not supported for this template.)  
   - Octoparse will automatically browse Yellow Pages Canada, load search results, scroll pages, and extract all matching listings.

4. **Monitor and handle interruptions**  
   - Scraping duration may vary based on the number of results.  
   - If a **CAPTCHA** appears, pause the task, solve it manually in the built-in browser, then resume.

5. **Export your data**  
   - After scraping completes, go to the **Data Preview** or output section.  
   - Export results as CSV or Excel for further analysis, filtering, or storage.

## Important Notes

- Use the format `Keyword;Location` with a semicolon only — no spaces before or after. Enter one query per line.
- Only publicly available Yellow Pages Canada listings are scraped. Results depend on keyword, location, and directory availability.
- Some listings may not display full contact details (e.g., phone, website). The scraper extracts only what is publicly shown.
- Large searches may take longer to complete.
- If a CAPTCHA appears, solve it manually.

## Limitations

Results depend on what the source site exposes at run time. Fields may be empty when a source page does not provide a value. The template enforces the input limits shown above.

## Tips

Use specific, valid inputs and review a representative result before starting a large batch. Remove duplicate inputs when repeated records are not needed.

## FAQ

### What do I need to enter?

Use the exact inputs and limits listed above.

### What data does this template return?

See Output Schema below; availability can vary by source record.

### How is usage billed?

See the Pricing section above for current pricing and billing details.

## Related Templates

- [Yellow Pages Canada Scraper (Business Details)](https://www.octoparse.com/template/yellow-pages-canada-scraper-business-details)
- [Yellow Pages Listing Scraper (Australia)](https://www.octoparse.com/template/yellow-pages-australia-scraper-product-listing)
- [Yellow Pages Spain Scraper(Listing)](https://www.octoparse.com/template/paginas-amarillas-listados-scraper)
- [Yellow Pages Scraper](https://www.octoparse.com/template/yellow-page-scraper)
- [Yellow Pages Details Scraper (Australia)](https://www.octoparse.com/template/yellow-pages-australia-scraper-product-details)

## Input Schema

```json
{
  "title": "Yellow Pages Canada Scraper (Business Listing) input",
  "description": "Input parameters configured for the current published template version.",
  "type": "object",
  "schemaVersion": 1,
  "additionalProperties": false,
  "properties": {
    "keyword_and_location": {
      "title": "Keyword and location (up to 20)",
      "description": "Enter a keyword and a location separated by a semicolon (no spaces). Each line represents one search query.",
      "type": "array",
      "items": {
        "type": "string",
        "minLength": 1,
        "maxLength": 5000
      },
      "minItems": 1,
      "maxItems": 20,
      "x-octoparse": {
        "apiEnabled": true
      }
    }
  },
  "required": [
    "keyword_and_location"
  ]
}
```

## Input JSON Example

Example 1

```json
{
  "keyword_and_location": [
    "restaurant;Toronto"
  ]
}
```

Example 2

```json
{
  "keyword_and_location": [
    "restaurant;Toronto"
  ]
}
```

Example 3

```json
{
  "keyword_and_location": [
    "restaurant;Toronto"
  ]
}
```

Example 4

```json
{
  "keyword_and_location": [
    "telephone systems;Toronto ON",
    "telephone systems;Montreal QC",
    "telephone systems;Vancouver BC",
    "telephone systems;Calgary AB",
    "telephone systems;Ottawa ON"
  ]
}
```

Example 5

```json
{
  "keyword_and_location": [
    "restaurant;Toronto"
  ]
}
```


## Output Schema

```json
{
  "schemaVersion": 1,
  "type": "object",
  "properties": {
    "Address": {
      "type": "string",
      "description": ""
    },
    "Business_name": {
      "type": "string",
      "description": ""
    },
    "Current_status": {
      "type": "string",
      "description": ""
    },
    "Description": {
      "type": "string",
      "description": ""
    },
    "Detail_URL": {
      "type": "string",
      "description": ""
    },
    "Editor_s_pick": {
      "type": "string",
      "description": ""
    },
    "Keyword": {
      "type": "string",
      "description": ""
    },
    "Location": {
      "type": "string",
      "description": ""
    },
    "Rating": {
      "type": "string",
      "description": ""
    },
    "Rating_count": {
      "type": "string",
      "description": ""
    },
    "Telephone": {
      "type": "string",
      "description": ""
    },
    "Website": {
      "type": "string",
      "description": ""
    }
  },
  "title": "Yellow Pages Canada Scraper (Business Listing) output",
  "description": "Initial output fields derived from the current published implementation. Field descriptions are maintained by Data Center; production field names and types should be refreshed from recent successful runs.",
  "additionalProperties": false
}
```

## Output Example

Example 1

```json
{
  "Address": "1975A Queen St E, Toronto, ON M4L 1J1",
  "Business_name": "La Sala Restaurant",
  "Current_status": "\nClosing soon",
  "Description": "\nExperience authentic Italian cuisine at La Sala Restaurant. Fresh ingredients, handcrafted dishes, and a warm atmosphere await. Perfect for dining, events, and unforgettable flavors!\nmore...\n\n",
  "Detail_URL": "https://www.yellowpages.ca/bus/Ontario/Toronto/La-Sala-Restaurant/2088985.html?what=restaurant&where=Toronto+ON&useContext=true",
  "Editor_s_pick": "√",
  "Keyword": "yellowpages.ca\",\"@id\":\"https://www.yellowpages.ca/#website\",\"@type\":\"WebSite\",\"@context\":\"https://schema.org\"},{\"sameAs\":[\"https://www.wikidata.org/wiki/Q2621318\",\"https://en.wikipedia.org/wiki/Yellow_Pages_Limited\",\"https://fr.wikipedia.org/wiki/Groupe_Pages_Jaunes\"],\"logo\":{\"url\":\"https://static.yellowpages.ca/ypca/ypui-7.3.12-20261111.1839/resources/images/verticals/yellowpages/logo-en.webp\",\"@type\":\"ImageObject\"},\"url\":\"https://www.yellowpages.ca/\",\"name\":\"Yellow Pages Canada\",\"@id\":\"https://www.yellowpages.ca/#organization\",\"@type\":\"Organization\",\"@context\":\"https://schema.org\"},{\"dateModified\":\"2026-11-18\",\"description\":\"Complete list of best restaurant ",
  "Location": "yellowpages.ca",
  "Rating": "4.5",
  "Rating_count": "4",
  "Telephone": "416-800-2993",
  "Website": "https://www.yellowpages.ca/gourl/13cbb0b210a022767cf9b26fea64bdd7dd92bebe?redirect=https%3A%2F%2Fwww.lasalaristorante.com%2F"
}
```

Example 2

```json
{
  "Address": "1975A Queen St E, Toronto, ON M4L 1J1",
  "Business_name": "La Sala Restaurant",
  "Current_status": "Closed now ",
  "Description": "\nExperience authentic Italian cuisine at La Sala Restaurant. Fresh ingredients, handcrafted dishes, and a warm atmosphere await. Perfect for dining, events, and unforgettable flavors!\nmore...\n\n",
  "Detail_URL": "https://www.yellowpages.ca/bus/Ontario/Toronto/La-Sala-Restaurant/2088985.html?what=restaurant&where=Toronto+ON&useContext=true",
  "Editor_s_pick": "√",
  "Keyword": "yellowpages.ca\",\"@id\":\"https://www.yellowpages.ca/#website\",\"@type\":\"WebSite\",\"@context\":\"https://schema.org\"},{\"logo\":{\"url\":\"https://static.yellowpages.ca/ypca/ypui-7.3.12-20261111.1839/resources/images/verticals/yellowpages/logo-en.webp\",\"@type\":\"ImageObject\"},\"sameAs\":[\"https://www.wikidata.org/wiki/Q2621318\",\"https://en.wikipedia.org/wiki/Yellow_Pages_Limited\",\"https://fr.wikipedia.org/wiki/Groupe_Pages_Jaunes\"],\"url\":\"https://www.yellowpages.ca/\",\"name\":\"Yellow Pages Canada\",\"@id\":\"https://www.yellowpages.ca/#organization\",\"@type\":\"Organization\",\"@context\":\"https://schema.org\"},{\"dateModified\":\"2026-11-12\",\"description\":\"Complete list of best restaurant ",
  "Location": "yellowpages.ca",
  "Rating": "4.5",
  "Rating_count": "4",
  "Telephone": "416-800-2993",
  "Website": "https://www.yellowpages.ca/gourl/13cbb0b210a022767cf9b26fea64bdd7dd92bebe?redirect=https%3A%2F%2Fwww.lasalaristorante.com%2F"
}
```

Example 3

```json
{
  "Address": "1975A Queen St E, Toronto, ON M4L 1J1",
  "Business_name": "La Sala Restaurant",
  "Current_status": "5:00 pm",
  "Description": "\nExperience authentic Italian cuisine at La Sala Restaurant. Fresh ingredients, handcrafted dishes, and a warm atmosphere await. Perfect for dining, events, and unforgettable flavors!\nmore...\n\n",
  "Detail_URL": "https://www.yellowpages.ca/bus/Ontario/Toronto/La-Sala-Restaurant/2088985.html?what=restaurant&where=Toronto+ON&useContext=true",
  "Editor_s_pick": "√",
  "Keyword": "yellowpages.ca\",\"@id\":\"https://www.yellowpages.ca/#website\",\"@type\":\"WebSite\",\"@context\":\"https://schema.org\"},{\"sameAs\":[\"https://www.wikidata.org/wiki/Q2621318\",\"https://en.wikipedia.org/wiki/Yellow_Pages_Limited\",\"https://fr.wikipedia.org/wiki/Groupe_Pages_Jaunes\"],\"logo\":{\"url\":\"https://static.yellowpages.ca/ypca/ypui-7.3.11-20260930.1535/resources/images/verticals/yellowpages/logo-en.webp\",\"@type\":\"ImageObject\"},\"url\":\"https://www.yellowpages.ca/\",\"name\":\"Yellow Pages Canada\",\"@id\":\"https://www.yellowpages.ca/#organization\",\"@type\":\"Organization\",\"@context\":\"https://schema.org\"},{\"dateModified\":\"2026-11-10\",\"description\":\"Complete list of best restaurant ",
  "Location": "yellowpages.ca",
  "Rating": "4.5",
  "Rating_count": "4",
  "Telephone": "416-800-2993",
  "Website": "https://www.yellowpages.ca/gourl/13cbb0b210a022767cf9b26fea64bdd7dd92bebe?redirect=https%3A%2F%2Fwww.lasalaristorante.com%2F"
}
```

Example 4

```json
{
  "Address": "1200 Saint Laurent Boulevard, Ottawa, ON K1K 3B8",
  "Business_name": "TELUS",
  "Current_status": "9:30 am",
  "Description": "",
  "Detail_URL": "https://www.yellowpages.ca/bus/Ontario/Ottawa/TELUS/100406572.html?what=telephone+systems&where=Ottawa+ON&useContext=true",
  "Editor_s_pick": "",
  "Keyword": "yellowpages.ca\",\"@id\":\"https://www.yellowpages.ca/#website\",\"@type\":\"WebSite\",\"@context\":\"https://schema.org\"},{\"sameAs\":[\"https://www.wikidata.org/wiki/Q2621318\",\"https://en.wikipedia.org/wiki/Yellow_Pages_Limited\",\"https://fr.wikipedia.org/wiki/Groupe_Pages_Jaunes\"],\"logo\":{\"url\":\"https://static.yellowpages.ca/ypca/ypui-7.3.11-20260930.1535/resources/images/verticals/yellowpages/logo-en.webp\",\"@type\":\"ImageObject\"},\"url\":\"https://www.yellowpages.ca/\",\"name\":\"Yellow Pages Canada\",\"@id\":\"https://www.yellowpages.ca/#organization\",\"@type\":\"Organization\",\"@context\":\"https://schema.org\"},{\"dateModified\":\"2026-11-10\",\"description\":\"Complete list of best telephone systems ",
  "Location": "yellowpages.ca",
  "Rating": "1",
  "Rating_count": "1",
  "Telephone": "613-748-3969",
  "Website": "https://www.yellowpages.ca/gourl/23490603e98d64f0113ecffcee8b79420bdbeefc?redirect=https%3A%2F%2Fstores.telus.com%2Fen%2Fon-ottawa-10186170"
}
```

Example 5

```json
{
  "Address": "1975A Queen St E, Toronto, ON M4L 1J1",
  "Business_name": "La Sala Restaurant",
  "Current_status": "5:00 pm",
  "Description": "\nExperience authentic Italian cuisine at La Sala Restaurant. Fresh ingredients, handcrafted dishes, and a warm atmosphere await. Perfect for dining, events, and unforgettable flavors!\nmore...\n\n",
  "Detail_URL": "https://www.yellowpages.ca/bus/Ontario/Toronto/La-Sala-Restaurant/2088985.html?what=restaurant&where=Toronto+ON&useContext=true",
  "Editor_s_pick": "√",
  "Keyword": "yellowpages.ca\",\"@id\":\"https://www.yellowpages.ca/#website\",\"@type\":\"WebSite\",\"@context\":\"https://schema.org\"},{\"logo\":{\"url\":\"https://static.yellowpages.ca/ypca/ypui-7.3.11-20260930.1535/resources/images/verticals/yellowpages/logo-en.webp\",\"@type\":\"ImageObject\"},\"sameAs\":[\"https://www.wikidata.org/wiki/Q2621318\",\"https://en.wikipedia.org/wiki/Yellow_Pages_Limited\",\"https://fr.wikipedia.org/wiki/Groupe_Pages_Jaunes\"],\"url\":\"https://www.yellowpages.ca/\",\"name\":\"Yellow Pages Canada\",\"@id\":\"https://www.yellowpages.ca/#organization\",\"@type\":\"Organization\",\"@context\":\"https://schema.org\"},{\"dateModified\":\"2026-10-14\",\"description\":\"Complete list of best restaurant ",
  "Location": "yellowpages.ca",
  "Rating": "4.5",
  "Rating_count": "4",
  "Telephone": "416-800-2993",
  "Website": "https://www.yellowpages.ca/gourl/13cbb0b210a022767cf9b26fea64bdd7dd92bebe?redirect=https%3A%2F%2Fwww.lasalaristorante.com%2F"
}
```

## API

`POST https://openapi.octoparse.com/api/agentTools/executeTask`

This is the OpenAPI Agent Tools `executeTask` endpoint. Authenticate with a Bearer token.

Request body:

`templateName` is the template slug; `parameters` is a JSON object string whose keys match Input Schema; `taskName`, `idempotencyKey`, and `maxCollectedRows` are optional.

Obtain a token:

```http
POST https://openapi.octoparse.com/token
Content-Type: application/json

{
  "username": "YOUR_USERNAME",
  "password": "YOUR_PASSWORD",
  "grant_type": "password"
}
```

Use `data.access_token` as `Authorization: Bearer <token>`. After starting, poll `getTaskStatus` and export with `exportData`.

```json
{
  "templateName": "yellow-pages-canada-scraper-product-listing",
  "taskName": "Yellow Pages Canada Scraper (Business Listing)",
  "parameters": "{\"keyword_and_location\":[\"restaurant;Toronto\"]}"
}
```

## Python Example

```python
import json
import requests

OPENAPI_BASE = "https://openapi.octoparse.com"
ACCESS_TOKEN = "YOUR_ACCESS_TOKEN"

parameters = json.loads("{\"keyword_and_location\":[\"restaurant;Toronto\"]}")

response = requests.post(
    f"{OPENAPI_BASE}/api/agentTools/executeTask",
    headers={
        "Authorization": f"Bearer {ACCESS_TOKEN}",
        "Content-Type": "application/json",
    },
    json={
        "templateName": "yellow-pages-canada-scraper-product-listing",
        "taskName": "Yellow Pages Canada Scraper (Business Listing)",
        "parameters": json.dumps(parameters, ensure_ascii=False),
    },
    timeout=60,
)
print(response.status_code)
print(response.json())
```

## HTTP/cURL Example

```bash
curl -X POST "https://openapi.octoparse.com/api/agentTools/executeTask" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  --data-binary @- <<'JSON'
{
  "templateName": "yellow-pages-canada-scraper-product-listing",
  "taskName": "Yellow Pages Canada Scraper (Business Listing)",
  "parameters": "{\"keyword_and_location\":[\"restaurant;Toronto\"]}"
}
JSON
```

## MCP Setup

Connect an MCP-compatible AI client to `https://mcp.octoparse.com` using browser OAuth or an Octoparse API key. Find `yellow-pages-canada-scraper-product-listing`, inspect its inputs, create a cloud task with the exact Input Schema keys, and export JSON results.

## Machine-readable Resources

- [Template contract](https://www.octoparse.com/templates/yellow-pages-canada-scraper-product-listing.json)
- [Manifest](https://www.octoparse.com/templates/yellow-pages-canada-scraper-product-listing-manifest.json)
