
Advanced Yellowpages Scraper
Pricing
$9.99/month + usage

Advanced Yellowpages Scraper
Yellowpages Scraper is a robust tool designed to scrape business information from Yellowpages. It efficiently extracts essential details such as business names, addresses, phone numbers, categories, and more.
0.0 (0)
Pricing
$9.99/month + usage
9
107
6
Last modified
3 days ago
Yellow Pages Scraper
Yellow Pages Scraper is an Apify actor designed for scraping information from Yellow Pages listings. It allows you to search records based on a combination of search terms and location or a list of URLs. Built on top of the Apify SDK, it can be run both on the Apify platform and locally.
Table of Contents
Input
Field | Type | Description | Default Value |
---|---|---|---|
site | string | Country/site key to target the correct Yellow Pages domain (e.g. us , ghana , nigeria , kenya , uganda ) | "us" |
search | string | Query string to be searched on the site | "Dentist" |
location | string | Location string to search the records in | "Los Angeles" |
startUrls | array | List of Request objects that will be deeply crawled. URLs may be absolute or relative to the configured site | none |
siteConfig | object | Advanced overrides for baseUrl , searchUrlTemplate , or CSS selectors when targeting unsupported domains | none |
maxItems | number | Maximum number of pages that will be scraped | 200 |
extendOutputFunction | string | Function that takes a Cheerio object and a Cheerio representation of the record element ($, record) as arguments and returns data that will be merged with the default output. More information in Extend Output Function | ($, record) => { return {}; } |
proxyConfiguration | object | Proxy settings of the run. If you have access to Apify proxy, you can set { "useApifyProxy": true } to enable proxy usage | { "useApifyProxy": false } |
Either the search
and location
attributes or the startUrls
attribute must be set.
Multi-site support
Set site
to one of the supported shortcuts to automatically adjust the base domain and default selectors. If the regional Yellow Pages instance uses different markup, provide a siteConfig
object with custom selectors or searchUrlTemplate
, or fall back to explicit startUrls
.
Currently bundled shortcuts: us
, ghana
, nigeria
, kenya
, uganda
.
Site key | Base domain(s) | Notes |
---|---|---|
us | https://www.yellowpages.com (also https://www.yp.com ) | Honour a ~5 s crawl delay; listings use .result cards and classic pagination. |
ghana | https://ghanayellowpages.com | WordPress-style listings in ul.results-list ; low-volume site—throttle to ≤1 rps. |
nigeria | https://yellowpagesnigeria.com | Mixed templates (.listing , .result , article ); selectors fallback across variants. |
kenya | https://yellow.co.ke | Uses “Load more” buttons; follow the link exposed in a.load-more to paginate. |
uganda | https://yellowpagesuganda.com | Service is unstable (frequent 5xx). Treat as best-effort and consider providing startUrls . |
Tip: respect each site’s
robots.txt
and Terms. Smaller directories react badly to high concurrency—stick to 1 request/second unless you know they can handle more.
Output
Output is stored in a dataset. Each item contains information about a record.
{"name": "The Modern NYC","address": "9 W 53rd St, New York, NY 10019","phone": "(212) 333-1220","website": "https://www.themodernnyc.com","rating": 4.7,"reviewSnippet": "A phenomenal dining experience with exquisite food and service. The best modern cuisine in NYC!","categories": ["Restaurants","Fine Dining","American Cuisine"],"url": "https://www.yelp.com/biz/the-modern-new-york"}
Please note that not all attributes will be present in all results.
Compute Units Consumption
Keep in mind that it is more efficient to run one longer scrape (at least one minute) than multiple shorter ones due to the startup time.
The average consumption is about 0.04 Compute Units per 2000 results scraped.
Extend Output Function
You can use this function to customize the default output of this actor. This function takes a Cheerio object and a Cheerio representation of the record element ($, record) as arguments, allowing you to add or modify attributes as needed. The output from this function will be merged with the default output.
The return value of this function must be an object!
You can return fields to achieve three different things:
- Add a new field: Return an object with a field that is not in the default output.
- Change a field: Return an existing field with a new value.
- Remove a field: Return an existing field with a value of
undefined
.
($, record) => {return {directionsLink: record.find('.directions').attr('href'),rating: 5,phone: undefined,}}
This example will add a new field directionsLink
, change the rating
field, and remove the phone
field.
Contact
For any questions or support, please contact us at support@example.com.
Connect With Us
- YouTube: Visit our channel
- Instagram: Follow us on Instagram
- AI Newsletter: Subscribe to our newsletter
- Free Consultation: Book a free consultation call
- More Tools: Explore our Apify actors
- Discord: Raise a Support ticket here
- Contact Email: codemasterdevops@gmail.com
On this page
Share Actor: