# BusinessesForSale Scraper (`shahidirfan/businessesforsale-scraper`) Actor

Extract business listings from BusinessesForSale with complete details, including business name, price, location, category, revenue, cash flow, description, images, broker information, and listing URL. Ideal for market research, lead generation, investment analysis, and business intelligence.

- **URL**: https://apify.com/shahidirfan/businessesforsale-scraper.md
- **Developed by:** [Shahid Irfan](https://apify.com/shahidirfan) (community)
- **Categories:** Lead generation, Automation, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.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.

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

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### What does BusinessesForSale Scraper do?

BusinessesForSale Scraper collects structured business-for-sale listings from BusinessesForSale.com. Use a public search URL such as `https://www.businessesforsale.com/search/hotels-for-sale`, or enter a keyword like `Gas Station` with an optional location term to create a search automatically.

The Actor is useful for buyers, brokers, analysts, investors, and lead generation teams that need business listing data in a clean dataset instead of manually copying titles, prices, locations, descriptions, and listing URLs.

### Why use BusinessesForSale Scraper?

- **Business acquisition research** - Build datasets of businesses for sale by category, keyword, or region.
- **Broker and investor workflows** - Track available opportunities, asking prices, revenue, cash flow, and market movement.
- **Automation-ready output** - Export listing data to JSON, CSV, Excel, XML, Google Sheets, webhooks, or your own systems.
- **Flexible search input** - Start from a BusinessesForSale URL or provide a keyword and location.
- **Pagination controls** - Set result and page limits so small tests and larger runs stay predictable.

### What data can you extract from BusinessesForSale.com?

| Field | Description |
|-------|-------------|
| `listing_id` | Source listing identifier when available |
| `title` | Business listing title |
| `url` | Direct listing URL |
| `description` | Short listing summary |
| `images` | Full listing image URLs when available |
| `location` | Business location when available |
| `price` | Numeric asking price when published in structured data |
| `currency` | Listing currency code |
| `asking_price` | Displayed asking price when available |
| `sales_revenue` | Displayed sales revenue when available |
| `revenue` | Displayed revenue or turnover when available |
| `cash_flow` | Displayed cash flow when available |
| `net_profit` | Displayed net profit when available |
| `real_estate` | Real estate or property inclusion status |
| `property` | Property type or ownership details |
| `premises_details` | Premises details when published |
| `expansion_potential` | Expansion notes when published |
| `reasons_for_selling` | Seller's reason for selling when published |
| `employees` | Employee or staffing details when published |
| `years_established` | Business age or year established when published |
| `contact_url` | Contact seller URL |
| `date_posted` | Published or updated date when available |
| `image_url` | Listing image URL |
| `source_url` | Search URL that produced the record |
| `scraped_at` | Collection timestamp |

### How to scrape BusinessesForSale.com data

1. Open the Actor on Apify.
2. Paste a BusinessesForSale search URL, or enter a keyword and optional location.
3. Set `results_wanted` and `max_pages`.
4. Keep proxy configuration enabled for reliable runs on Apify.
5. Run the Actor and download the dataset or connect it to another tool.

### Input Parameters

| Parameter | Type | Required | Default | Description |
|-----------|------|----------|---------|-------------|
| `startUrl` | String | No | - | BusinessesForSale search URL. Takes priority over keyword and location. |
| `keyword` | String | No | - | Search keyword used when no start URL is provided. |
| `location` | String | No | - | Optional location term combined with the keyword search. |
| `results_wanted` | Integer | No | `20` | Maximum number of listings to save. |
| `max_pages` | Integer | No | `5` | Maximum number of result pages to process. |
| `collectDetails` | Boolean | No | `false` | Optional slower mode for extra fields from each listing page. Keep disabled for fast batch runs. |
| `proxyConfiguration` | Object | No | Apify Proxy | Proxy settings for reliable collection. |

### Usage Examples

#### Scrape a category URL

Collect hotel listings from a public BusinessesForSale search page:

```json
{
  "startUrl": "https://www.businessesforsale.com/search/hotels-for-sale",
  "results_wanted": 20,
  "max_pages": 2,
  "collectDetails": false
}
```

#### Search by keyword

Collect business listings matching a keyword:

```json
{
  "keyword": "Gas Station",
  "results_wanted": 20,
  "max_pages": 1,
  "collectDetails": false
}
```

#### Search by keyword and location

Combine a business type with a location term:

```json
{
  "keyword": "Restaurant",
  "location": "Florida",
  "results_wanted": 50,
  "max_pages": 3,
  "collectDetails": false
}
```

### Sample Output

```json
{
  "listing_id": "3985556",
  "title": "Exclusive-Use Country House Venue In Exmoor National Park",
  "url": "https://uk.businessesforsale.com/uk/exclusive-use-country-house-venue-in-exmoor-national-park.aspx",
  "description": "A rare opportunity to acquire a beautifully restored, exclusive-use country house wedding and events venue.",
  "images": [
    "https://uk.businessesforsale.com/uploads/be62e16c-bb0d-4c85-bf88-b49a0166e733.jpg"
  ],
  "price": 3600000,
  "currency": "GBP",
  "location": "Somerset, GB",
  "asking_price": "£3,600,000",
  "sales_revenue": "£500,000",
  "cash_flow": "£250,000",
  "real_estate": "Freehold",
  "premises_details": "Country House Estate",
  "expansion_potential": "Huge potential",
  "reasons_for_selling": "Retirement",
  "contact_url": "https://uk.businessesforsale.com/uk/exclusive-use-country-house-venue-in-exmoor-national-park/contact",
  "image_url": "https://www.businessesforsale.com/uploadsstatic/a3985556mediumthumbnail.jpg",
  "source_url": "https://www.businessesforsale.com/search/hotels-for-sale",
  "scraped_at": "2026-08-04T10:30:00.000Z"
}
```

### Tips for Best Results

- Use complete BusinessesForSale search URLs for exact category or country searches.
- Start with `results_wanted` set to `20` when testing a new search.
- Increase `max_pages` only when you need more results than the first page provides.
- Use category pages when you want broader market coverage and keyword search when you want specific business types.
- Some financial fields may be missing when the seller does not publish them.

### Integrations

- **Google Sheets** - Send business listings to a spreadsheet for review.
- **CSV and Excel** - Download datasets for market research and reporting.
- **Webhooks** - Trigger workflows after each run finishes.
- **Make or Zapier** - Connect listing data to no-code automation.
- **API** - Access datasets programmatically from your own apps.

### Frequently Asked Questions

#### Can I scrape a BusinessesForSale search URL directly?

Yes. Paste the public search URL into `startUrl`, and the Actor will use that URL before keyword or location inputs.

#### Can I search by keyword instead of URL?

Yes. Leave `startUrl` empty and provide `keyword`, with `location` if needed.

#### Can I collect more than one page?

Yes. Increase `max_pages` and `results_wanted` to collect additional paginated results.

#### Why are some fields missing from some records?

Some sellers do not publish asking price, revenue, cash flow, images, or dates. Empty values are removed from each dataset item.

#### Can I export BusinessesForSale data to CSV or Excel?

Yes. Apify datasets can be exported to CSV, Excel, JSON, XML, RSS, and other formats.

#### Is it legal to scrape BusinessesForSale.com?

Scraping public web data can be legal, but you are responsible for following applicable laws, website terms, and privacy rules. Use the Actor for legitimate research and compliance-friendly workflows.

### Support

For issues, feature requests, or custom Actor work, use the Issues tab on the Actor page or contact the developer through Apify.

### Legal Notice

This Actor is designed for collecting publicly available business listing data. Users are responsible for using the data responsibly and complying with applicable laws, platform terms, and data protection requirements.

# Actor input Schema

## `startUrl` (type: `string`):

BusinessesForSale search URL to scrape. This takes priority over keyword and location.

## `keyword` (type: `string`):

Search keyword to use when Start URL is not provided.

## `location` (type: `string`):

Optional location term to combine with the keyword search.

## `results_wanted` (type: `integer`):

Maximum number of listings to save.

## `max_pages` (type: `integer`):

Maximum number of search result pages to process.

## `collectDetails` (type: `boolean`):

Optional slower mode that opens each listing URL for extra fields. Keep disabled for fast batch collection.

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

Proxy settings for reliable collection on Apify.

## Actor input object example

```json
{
  "startUrl": "https://www.businessesforsale.com/search/hotels-for-sale",
  "keyword": "Gas Station",
  "location": "United States",
  "results_wanted": 20,
  "max_pages": 5,
  "collectDetails": false,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `overview` (type: `string`):

No description

# 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 = {
    "startUrl": "https://www.businessesforsale.com/search/hotels-for-sale",
    "keyword": "Gas Station",
    "location": "United States",
    "results_wanted": 20,
    "max_pages": 5
};

// Run the Actor and wait for it to finish
const run = await client.actor("shahidirfan/businessesforsale-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 = {
    "startUrl": "https://www.businessesforsale.com/search/hotels-for-sale",
    "keyword": "Gas Station",
    "location": "United States",
    "results_wanted": 20,
    "max_pages": 5,
}

# Run the Actor and wait for it to finish
run = client.actor("shahidirfan/businessesforsale-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "startUrl": "https://www.businessesforsale.com/search/hotels-for-sale",
  "keyword": "Gas Station",
  "location": "United States",
  "results_wanted": 20,
  "max_pages": 5
}' |
apify call shahidirfan/businessesforsale-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=shahidirfan/businessesforsale-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/0vbuOGDzFRBm5sEcZ/builds/IKwmSG22pfMAZeg70/openapi.json
