# Instagram Contact Scraper — Email & Phone Extractor (`khadinakbar/instagram-contact-scraper`) Actor

Extract emails and phone numbers from public Instagram profiles. Business/creator accounts, bio parse, and bio links. Provider-backed (ScrapeCreators + SociaVault), no login. MCP-ready.

- **URL**: https://apify.com/khadinakbar/instagram-contact-scraper.md
- **Developed by:** [Khadin Akbar](https://apify.com/khadinakbar) (community)
- **Categories:** Social media, Lead generation, MCP servers
- **Stats:** 2 total users, 1 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event + usage

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## Instagram Contact Scraper — Email & Phone Extractor

Extract **emails and phone numbers** from public Instagram profiles in bulk. Designed for B2B lead generation, influencer outreach, and contact enrichment pipelines.

### What You Get

| Field | Description |
|-------|-------------|
| `email` | Best email found: `business_email` → `public_email` → bio regex |
| `phone` | Best phone: `business_phone_number` → bio regex |
| `bioEmails` | All emails extracted from the biography and bio links |
| `bioPhones` | All phone numbers extracted from the biography and bio links |
| `bioLinks` | All URLs in the bio (external\_url + bio\_links) |
| `username` | Instagram handle |
| `fullName` | Display name |
| `followersCount` | Follower count |
| `isBusinessAccount` | True for business/creator accounts |
| `businessCategory` | e.g. "Clothing (Brand)" |
| `isVerified` | Blue badge status |
| `isPrivate` | Private account flag |
| `profileUrl` | Canonical IG profile URL |
| `source` | Data path: `scrapecreators` → `sociavault` → `native` |
| `hasContact` | `true` if email or phone found — quick filter column |
| `scrapedAt` | ISO 8601 timestamp |

### Why Use This Instead of the Profile Scraper?

- **Contact-focused output** — lighter record, no post data, built for CRM imports
- **`onlyWithContact` filter** — skip and don't charge for profiles with no contact info
- **Dual extraction paths** — structured business fields + bio regex both run
- **Provider-backed** — ScrapeCreators primary, SociaVault fallback, no login or cookies ever

### Pricing

| Event | Price |
|-------|-------|
| `contact-found` (has email or phone) | $0.003 |
| `profile-no-contact` (reached, no contact) | $0.001 |
| `apify-actor-start` | $0.00005 |

Use `onlyWithContact: true` to avoid the $0.001 charge on contactless profiles.

### Quick Start

```json
{
  "usernames": ["garyvee", "hubspot", "nike", "natgeo"]
}
```

### Input Options

| Field | Type | Default | Description |
|-------|------|---------|-------------|
| `usernames` | string\[] | required | Handles, @handles, or profile URLs |
| `onlyWithContact` | boolean | false | Skip & don't charge profiles with no email/phone |
| `maxItems` | integer | unlimited | Stop after N profiles (budget cap) |

### Agent Prompt Card (MCP)

```
Use apify--instagram-contact-scraper to extract email and phone from Instagram profiles.
Input: usernames (array of handles or profile URLs).
Returns: email, phone, bioEmails, bioPhones, hasContact, source per profile.
Pricing: $0.003 if contact found, $0.001 if not, $0.00005 actor start.
Set onlyWithContact: true to only return and charge for profiles that have contact info.
```

### API Example

```bash
curl -X POST https://api.apify.com/v2/acts/khadinakbar~instagram-contact-scraper/runs \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -d '{"usernames":["garyvee","hubspot"],"onlyWithContact":true}'
```

### Builder's Notes

Business and creator accounts on Instagram expose `business_email` and `business_phone_number` in Instagram's public web profile JSON. This actor checks those structured fields first, then falls back to bio regex parsing — extracting any email or phone text that appears in the biography or linked URLs. GaryVee, for example, puts his text number directly in his bio; the regex picks it up.

ScrapeCreators resolves most profiles within 1–2 seconds cookieless. SociaVault is wired as Tier-2 for redundancy. The native CheerioCrawler (with Apify Residential proxy) is Tier-3 for any unresolved handles.

### Legal

This actor scrapes only public, non-logged-in Instagram profile data. It does not access DMs, private profiles, followers lists, or any login-gated content. Use the collected data in compliance with Instagram's Terms of Service and applicable data protection laws (GDPR, CCPA). The actor author assumes no responsibility for downstream use of scraped data.

### Related Actors

- [instagram-profile-scraper](https://apify.com/khadinakbar/instagram-profile-scraper) — Full profile with recent posts
- [instagram-posts-scraper](https://apify.com/khadinakbar/instagram-posts-scraper) — Post-level data
- [linkedin-profile-email-scraper](https://apify.com/khadinakbar/linkedin-profile-email-scraper) — LinkedIn equivalent
- [bulk-website-contact-extractor](https://apify.com/khadinakbar/bulk-website-contact-extractor) — Extract contacts from any website

# Actor input Schema

## `usernames` (type: `array`):

One or more Instagram accounts to extract contact info from. Accepts bare usernames ('nike'), @-handles ('@nasa'), or full profile URLs ('https://instagram.com/hubspot'). Business and creator accounts are most likely to have email/phone. Returns one record per profile.

## `onlyWithContact` (type: `boolean`):

When true, only profiles that have at least one email or phone number are pushed to the dataset. Profiles with no contact data are silently skipped (not billed). Useful for lead-gen pipelines where you only want actionable rows. Default: false (all profiles saved).

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

Stop after processing this many profiles. Useful for budget control on large lists. Defaults to unlimited (all supplied usernames).

## Actor input object example

```json
{
  "usernames": [
    "nike",
    "@garyvee",
    "https://www.instagram.com/hubspot/"
  ],
  "onlyWithContact": false,
  "maxItems": 100
}
```

# Actor output Schema

## `contacts` (type: `string`):

Dataset items with username, email, phone, bioEmails, bioPhones, bioLinks, hasContact, source, and profileUrl.

## `summary` (type: `string`):

Run outcome, totalProfiles, contactsFound, and itemsPushed.

## `runSummary` (type: `string`):

Machine-readable RUN\_SUMMARY record mirroring OUTPUT for integrations that read RUN\_SUMMARY directly.

# 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 = {
    "usernames": [
        "humansofny",
        "natgeo",
        "nasa"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("khadinakbar/instagram-contact-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 = { "usernames": [
        "humansofny",
        "natgeo",
        "nasa",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("khadinakbar/instagram-contact-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 '{
  "usernames": [
    "humansofny",
    "natgeo",
    "nasa"
  ]
}' |
apify call khadinakbar/instagram-contact-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,khadinakbar/instagram-contact-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/TtmjIptjSXepkD0fP/builds/0xLwdFqqmNk3u0zCg/openapi.json
