# Instagram Profile Email Scraper By Keyword (`scrapers-hub/instagram-profile-email-scraper-by-keyword`) Actor

Instagram Profile Email Scraper By Keyword finds creator and business accounts by topic and extracts emails, bio, followers, following, post count, verification and business flags. 📩 Purpose-built for influencer outreach and B2B lead gen.

- **URL**: https://apify.com/scrapers-hub/instagram-profile-email-scraper-by-keyword.md
- **Developed by:** [Scrapers Hub](https://apify.com/scrapers-hub) (community)
- **Categories:** Lead generation, Social media, Automation
- **Stats:** 1 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.99 / 1,000 results

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/actors/running/actors-in-store.md#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 Profile Email Scraper by Keyword – Influencer Leads, Bios & Follower Data

The **Instagram Profile Email Scraper by Keyword** discovers Instagram profiles matching the keywords you supply and returns structured lead records containing the username, full name, biography, follower and following counts, post count, verification and business-account flags, profile picture URLs, external link and any email addresses found in the bio. Give it a keyword like `fitness` or `photography` and it returns a ready-to-use influencer prospect list rather than a page of search results you still have to read.

This Instagram email scraper is aimed at people doing real outreach work: influencer marketing managers building creator shortlists, agencies qualifying partners by audience size, B2B teams sourcing niche contacts, and researchers mapping who is active in a topic. Each record is flat, consistently shaped and tagged with the keyword that produced it, so a multi-keyword run stays analysable rather than turning into an undifferentiated pile.

Only publicly visible profile information is collected. Nothing behind a private account or a login is touched.

***

### 📊 What Data Can You Extract with This Instagram Profile Email Scraper?

Each row in the dataset is one Instagram profile, enriched with contact details where the account has published them.

| Category | Fields | What it gives you |
|---|---|---|
| 📬 Contact data | `emails`, `external_url` | Email addresses extracted from the profile bio, plus the link the account points to in its profile |
| 👤 Profile identity | `username`, `full_name`, `user_id`, `url` | The account handle, display name, numeric user identifier and canonical profile URL |
| 📈 Audience metrics | `followers`, `following`, `post_count` | Follower count, following count and total posts — the three numbers that drive influencer tier and engagement estimates |
| ✅ Account status | `is_verified`, `is_business_account`, `is_professional_account` | Whether the account carries the verified badge, and whether it is set up as a business or professional profile |
| 📝 Bio content | `biography` | The full profile biography text, including any contact details, niche descriptors or calls to action the account has written |
| 🖼️ Imagery | `profile_pic_url`, `profile_pic_url_hd` | Standard and high-definition profile picture URLs for building visual shortlists and media kits |
| 🔍 Search provenance | `keyword` | The exact search keyword that produced this profile, so multi-keyword runs stay attributable |

The most decision-useful combination in this output is `followers` alongside `is_business_account` and `emails`. A profile with a mid-size follower count, a business account flag and a published email is a creator who has deliberately set themselves up to be contacted for partnerships — a materially better prospect than a larger account with no contact route at all. Filtering on those three fields turns a raw profile list into a genuinely qualified pipeline.

***

### 🌟 Key Features of the Instagram Profile Email Scraper

| Feature | Description |
|---|---|
| 🔑 Multi-keyword discovery | The `keywords` array accepts any number of search terms and each one is searched separately, with the originating keyword stamped on every result row |
| 📧 Email-only filtering | Enable `scrapeLeadsWithEmail` to target profiles that carry an address in the bio from common providers such as Gmail, Hotmail, Outlook and Yahoo, rather than returning every matching profile |
| 🌍 Country targeting | Choose from 26 supported countries in the `country` selector — United States, United Kingdom, Canada, Australia, India, Germany, France, Brazil, Japan, UAE and more — or leave it to target broadly |
| 🎚️ Per-keyword result cap | `maxLeadsPerKeyword` bounds how many leads each keyword collects (1–500), keeping run size and cost predictable across a broad keyword set |
| 📊 Full audience metrics | Every profile returns `followers`, `following` and `post_count`, so you can filter by influencer tier and follower-to-following ratio without a second enrichment step |
| 🏅 Account-type signals | `is_verified`, `is_business_account` and `is_professional_account` distinguish casual accounts from creators and brands that expect commercial contact |
| 🔗 Website and link capture | `external_url` returns the link in the profile — often a linktree, shop or portfolio that reveals far more about a creator's commercial setup than the bio alone |
| 🔄 Automatic proxy rotation | Requests are routed through rotating proxy infrastructure automatically, with no proxy configuration or credentials required from you |
| ⚡ Browser-free execution | Profiles are retrieved over direct HTTP with browser-grade TLS fingerprints and parsed with a fast selector engine, keeping runs light and predictable |

***

### 🚀 Why Choose This Instagram Profile Email Scraper?

**Contact details and qualification data arrive together.** Most email scrapers hand you an address and nothing else, leaving you to enrich it later. Here `emails` comes attached to `followers`, `biography`, `is_business_account` and `external_url` in the same row, so you can qualify and prioritise a list the moment the run finishes.

**Keyword-first discovery, not URL-first.** You do not need a pre-existing list of profiles. Supply the topics you care about and the Actor finds the accounts, which is the difference between researching a niche and merely re-scraping one you already know.

**Cost is bounded per keyword, not per run.** `maxLeadsPerKeyword` caps each search term independently, so adding a speculative keyword to a run cannot blow up the total. A ten-keyword run with a cap of 20 has a predictable ceiling regardless of how deep any individual niche goes.

**Email targeting is a switch, not a post-process.** Turning on `scrapeLeadsWithEmail` focuses the search on profiles that publish an address in the bio, so you are not paying to collect thousands of uncontactable accounts and filtering them out afterwards.

***

### 📥 Input

```json
{
  "keywords": ["marketing", "fitness"],
  "country": "United States",
  "maxLeadsPerKeyword": 20,
  "scrapeLeadsWithEmail": false
}
```

#### 🔧 Instagram Profile Email Scraper Input Fields

| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| `keywords` | array | ✅ Yes | `["marketing", "fitness"]` (prefill) | List of keywords to search for Instagram profiles (e.g. `marketing`, `fitness`, `photography`). Each keyword is searched separately |
| `country` | string (enum) | No | `"United States"` | Filter results by country. Leave empty for worldwide results. Options: United States, United Kingdom, Canada, Australia, India, Germany, France, Spain, Italy, Brazil, Mexico, Japan, South Korea, China, Singapore, United Arab Emirates, Netherlands, Sweden, Norway, Denmark, Switzerland, Belgium, Austria, Ireland, New Zealand, South Africa |
| `maxLeadsPerKeyword` | integer | No | `20` | Maximum number of leads to collect for each keyword (1–500) |
| `scrapeLeadsWithEmail` | boolean | No | `false` | If enabled, searches for profiles that have emails in their bio (using common email providers like Gmail, Hotmail, Outlook, Yahoo). If disabled, finds all profiles matching keywords |

#### 💡 Input Examples

**Email-only influencer prospecting in the UK:**

```json
{
  "keywords": ["skincare", "beauty"],
  "country": "United Kingdom",
  "maxLeadsPerKeyword": 100,
  "scrapeLeadsWithEmail": true
}
```

**Broad worldwide niche mapping:**

```json
{
  "keywords": ["photography", "videographer", "content creator"],
  "country": "",
  "maxLeadsPerKeyword": 50
}
```

**Deep single-niche harvest:**

```json
{
  "keywords": ["vegan recipes"],
  "country": "Canada",
  "maxLeadsPerKeyword": 500,
  "scrapeLeadsWithEmail": true
}
```

***

### 📤 Output

```json
{
  "keyword": "fitness",
  "url": "https://www.instagram.com/example_fitness_coach/",
  "username": "example_fitness_coach",
  "full_name": "Example Fitness Coach",
  "biography": "Certified PT | Online coaching programmes | Collabs: example.coach@gmail.com",
  "emails": ["example.coach@gmail.com"],
  "user_id": "1234567890",
  "followers": 48200,
  "following": 812,
  "post_count": 1043,
  "is_verified": false,
  "is_business_account": true,
  "external_url": "https://example-coaching.com"
}
```

#### 🧾 Instagram Profile Output Fields

| Field | Type | Description |
|---|---|---|
| `keyword` | string | null | Keyword that produced this item |
| `url` | string | null | Canonical URL of the scraped item |
| `username` | string | null | Account handle or username |
| `biography` | string | null | Profile biography text |
| `emails` | array | null | Email addresses found for the item |
| `user_id` | string | null | Identifier of the user |
| `full_name` | string | null | Full display name |
| `followers` | integer | null | Number of followers |
| `following` | integer | null | Number of accounts followed |
| `post_count` | integer | null | Number of posts |
| `is_verified` | boolean | null | Whether the account is verified |
| `is_business_account` | boolean | null | Whether the account is a business account |
| `is_professional_account` | boolean | null | Whether the account is a professional account |
| `profile_pic_url` | string | null | URL of the item's profile picture |
| `profile_pic_url_hd` | string | null | High-definition profile picture URL |
| `external_url` | string | null | URL of the item's external link |

`emails` is an array because a bio can list more than one address — a personal one and a management or booking address, for instance. Profiles with no published address return an empty array when `scrapeLeadsWithEmail` is off.

***

### 💻 How to Use the Instagram Profile Email Scraper (Step by Step)

#### Step 1: Choose Keywords That Describe the Niche, Not the Person

The `keywords` array drives everything, and the terms that work best are the ones creators use to describe themselves in their own bios. "vegan recipes", "strength coach" and "wedding photographer" produce far tighter results than "food", "fitness" or "photo". Start with three to six specific terms rather than a long list of generic ones — you can always add more once you see which shapes of keyword return the profile types you want.

#### Step 2: Set the Country Filter to Match Your Market

`country` defaults to United States and offers 26 options covering North America, Europe, Asia-Pacific, Latin America, the Middle East and South Africa. Set it to the market you actually sell into: a creator list is only useful if the audience overlaps your customers. Leaving the field empty returns worldwide results, which suits niche mapping and category research but produces a list you will have to segment yourself afterwards.

#### Step 3: Decide Whether You Need Emails Specifically

`scrapeLeadsWithEmail` is the single most consequential toggle in the input. Leave it `false` when you are mapping a niche and want the widest possible view of who is active in it. Switch it to `true` when the run's purpose is outreach and a profile without a published address is worthless to you — the search then focuses on profiles carrying an address from common providers such as Gmail, Hotmail, Outlook or Yahoo in the bio.

#### Step 4: Size the Run with `maxLeadsPerKeyword`

This integer accepts values from 1 to 500 and applies to each keyword independently, so it is the lever that keeps a multi-keyword run predictable. For a first exploratory pass, 20 per keyword across several terms tells you quickly which keywords are productive without a large spend. Once a keyword has proved itself, re-run that one alone with a much higher cap to harvest the niche properly.

#### Step 5: Launch the Run and Monitor Progress

Start the Actor from the Apify console or trigger it through the API. The log reports which keyword is being processed and how many profiles have been collected, so you can see early whether a keyword is returning results at the rate you expected. A keyword that stalls at a handful of profiles is usually too narrow or too generic — note it for the refinement pass rather than waiting for the whole run to end.

#### Step 6: Filter and Qualify the Dataset

Open the finished dataset and sort or filter before exporting. Useful first cuts: profiles where `emails` is non-empty, `followers` sits in your target tier, and `is_business_account` is true. Then read `biography` for the shortlist — it is where creators state their rates policy, their niche and whether they accept collaborations. `external_url` is worth opening for anyone who reaches the final list, since a media kit or shop page tells you more about commercial readiness than any metric.

#### Step 7: Export and Push into Your Outreach Workflow

Export as CSV for a spreadsheet or CRM import, or JSON if you want the `emails` array preserved as a list rather than flattened into a cell. Key your records on `user_id` rather than `username`, because handles change and the numeric identifier does not. From there, use the Apify integrations to push new leads automatically into your CRM or outreach sequencing tool as scheduled runs discover them.

***

### 🔌 API Access & Integrations

Run the Instagram Profile Email Scraper synchronously and receive dataset items directly:

```bash
curl -X POST "https://api.apify.com/v2/acts/scrapers-hub~instagram-profile-email-scraper-by-keyword/run-sync-get-dataset-items?token=YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "keywords": ["marketing", "fitness"],
    "country": "United States",
    "maxLeadsPerKeyword": 20,
    "scrapeLeadsWithEmail": true
  }'
```

Or call it from Python with the official client:

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_TOKEN")

run_input = {
    "keywords": ["skincare", "beauty"],
    "country": "United Kingdom",
    "maxLeadsPerKeyword": 100,
    "scrapeLeadsWithEmail": True,
}

run = client.actor(
    "scrapers-hub/instagram-profile-email-scraper-by-keyword"
).call(run_input=run_input)

for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    if item.get("emails"):
        print(item["username"], item["followers"], item["emails"])
```

Runs can also be connected to Zapier, Make, Google Sheets, Slack or a custom webhook, so newly discovered Instagram leads flow into your CRM or outreach tool without manual exports.

***

### 💡 Best Use Cases for Instagram Profile Email Data

#### 🤝 Influencer Discovery and Outreach

Build a creator shortlist for a campaign by running niche keywords with `scrapeLeadsWithEmail` enabled, then filter on `followers` to hit your target tier. `emails` gives you a direct route to the creator, `biography` usually states whether they take collaborations, and `is_business_account` flags accounts already configured for commercial partnerships.

#### 📊 Competitive and Niche Landscape Mapping

Run a broad keyword set with the email filter off to see who is genuinely active in a category. Aggregating `followers`, `post_count` and `is_verified` across the results reveals the shape of the niche — whether it is dominated by a few large verified accounts or spread across many mid-tier creators — which directly informs how much budget a campaign there will need.

#### 🎯 Lead Generation for Agencies and Service Providers

Social media agencies, photographers, coaches and SaaS vendors can find prospects who have publicly identified themselves as being in a target segment. The combination of `emails` for contact, `external_url` for their existing web presence and `biography` for their positioning gives you enough to write a genuinely specific first message rather than a template.

#### 🏷️ Brand Ambassador and Affiliate Recruitment

Recruiting ambassadors means finding people with engaged niche audiences rather than the largest possible following. Filtering on a mid-range `followers` count with a low `following` count identifies accounts whose audience came from content rather than follow-back tactics, and `emails` provides the recruitment channel.

#### 🔍 Audience Research and Content Strategy

The `biography` field across hundreds of profiles in one niche is a compact corpus of how practitioners describe themselves. Running text analysis over it surfaces the vocabulary, credentials and calls to action that dominate a category — useful input for your own positioning, ad copy and profile optimisation regardless of whether you contact anyone.

#### 🌐 Market Entry and Regional Expansion Planning

The `country` selector lets you run the same keyword set across several markets and compare results side by side. Differences in profile density, typical `followers` counts and business-account adoption between, say, Germany and Brazil are a fast, cheap read on how developed the creator economy is in each before you commit to a market.

#### 🗂️ CRM Enrichment for Existing Contacts

If you already hold a list of niche contacts, a keyword run over the same segment can supply the social layer you are missing — `username`, `followers`, `external_url` and `profile_pic_url` — matched on email address. Enriching an existing CRM with audience metrics makes prioritisation far more informed than firmographic data alone.

***

### ⚙️ Tips for Better Instagram Profile Scraping Results

- **Write keywords the way creators write bios.** Terms that appear verbatim in profile text — "personal trainer", "wedding photographer", "vegan chef" — outperform abstract category words every time.
- **Explore first with a low cap, then harvest.** Run six keywords at `maxLeadsPerKeyword` of 20 to find which are productive, then re-run the two or three winners alone at 300–500. This costs far less than running everything deep from the start.
- **Turn on `scrapeLeadsWithEmail` only when contact is the goal.** For research and landscape mapping the filter throws away valuable profiles; for outreach it removes the ones you cannot act on. Match the toggle to the purpose of the run.
- **Use the follower-to-following ratio as a quality signal.** A profile with 40,000 `followers` and 500 `following` reads very differently from one with 40,000 and 38,000. The ratio is a quick proxy for whether an audience was earned or reciprocated.
- **Join on `user_id`, not `username`.** Instagram handles change; the numeric identifier is stable. Store both, but make the identifier your key when de-duplicating across runs.
- **Verify addresses and respect consent before sending.** Bio emails are published for contact, but that is not blanket consent for bulk marketing. Verify deliverability, personalise, and honour opt-outs in line with the rules that apply to your recipients.

***

### 🛠️ Troubleshooting

**Most of my results have an empty `emails` array.**
That is expected when `scrapeLeadsWithEmail` is left at its default of `false`, because the run then returns all matching profiles rather than only contactable ones. Set it to `true` if published addresses are the point of the run. Bear in mind that even then, only addresses from common providers written into the bio can be found — creators who share contact details only through a linked page will not surface.

**A keyword returned far fewer profiles than `maxLeadsPerKeyword`.**
The cap is a ceiling, not a target. Very narrow keywords, or narrow keywords combined with a restrictive `country`, simply do not have that many matching public profiles. Broaden the term, remove the country filter, or accept that the niche is smaller than you assumed — which is itself a useful finding.

**Results are not from the country I selected.**
Country targeting works on the signals available in public profile and search data, and creators do not always publish or match a clear location. Treat `country` as a strong bias rather than a guarantee, and confirm geography from `biography` and `external_url` for anyone who reaches your shortlist.

**Follower counts differ from what I see in the app.**
Instagram counts move continuously and are rounded in some surfaces. Metrics in the dataset reflect the moment the profile was fetched. For campaign decisions, treat `followers` as an accurate tier indicator rather than an exact real-time figure.

**My CSV export shows `emails` as a single messy cell.**
`emails` is an array so it can hold multiple addresses per profile. CSV flattens it into one cell. Export JSON if you want the list preserved as a structure, or split the cell on the delimiter after import if your CRM needs one address per row.

***

### ❓ Frequently Asked Questions About Instagram Profile Email Scraping

**What does the Instagram Profile Email Scraper extract?**
For each discovered profile it returns the username, full name, user ID, profile URL, biography, any email addresses found in the bio, follower count, following count, post count, verified and business/professional account flags, standard and HD profile picture URLs, the external link, and the keyword that produced the match.

**Do I need a list of Instagram usernames to start?**
No. This scraper is keyword-driven — you supply search terms such as `fitness` or `photography` and it discovers matching profiles for you. That is what makes it suitable for finding creators you do not already know about.

**How do I get only profiles that have an email address?**
Set `scrapeLeadsWithEmail` to `true`. The search then targets profiles carrying an address from common providers such as Gmail, Hotmail, Outlook or Yahoo in the bio, instead of returning every profile matching your keywords.

**How many Instagram leads can I collect per run?**
`maxLeadsPerKeyword` accepts 1 to 500 and applies to each keyword independently, so a five-keyword run at the maximum setting can reach up to 2,500 profiles. Actual volume depends on how many public profiles genuinely match each term.

**Which countries can I target?**
Twenty-six: the United States, United Kingdom, Canada, Australia, India, Germany, France, Spain, Italy, Brazil, Mexico, Japan, South Korea, China, Singapore, United Arab Emirates, Netherlands, Sweden, Norway, Denmark, Switzerland, Belgium, Austria, Ireland, New Zealand and South Africa. Leave the field empty for worldwide results.

**Does this Instagram scraper access private accounts?**
No. It collects only publicly visible profile information. Private accounts, direct messages, and anything requiring a login are outside its scope entirely.

**Do I have to configure proxies?**
No. Proxy rotation is handled automatically inside the Actor. There is no proxy configuration field, no credentials to supply and no IP pool for you to manage.

**Why do some profiles have several email addresses?**
The `emails` field is an array because bios frequently list more than one address — for example a general contact and a separate management or booking address. All addresses matched in the bio are returned.

**Can I use the follower counts to estimate engagement?**
`followers`, `following` and `post_count` give you the standard tier and activity signals, and the follower-to-following ratio is a useful quality proxy. True engagement rate requires per-post interaction data, which is not part of this Actor's output.

**What is the difference between a business account and a professional account?**
`is_business_account` marks profiles configured specifically as businesses, while `is_professional_account` covers the broader professional category that includes creator accounts. Both indicate an account set up for commercial activity, which usually means the owner expects partnership enquiries.

**How should I choose keywords for influencer discovery?**
Use the self-descriptions creators actually write in their bios — job titles, specialisms and niche phrases — rather than broad category nouns. Test several with a low `maxLeadsPerKeyword`, see which return the profile types you want, then harvest the winners deeply.

**Is scraping Instagram profile emails legal?**
The Actor collects only publicly available information. How you use it is governed by privacy and marketing law in your jurisdiction, including the GDPR, the UK Data Protection Act, CAN-SPAM and CASL. Establish a lawful basis before contacting anyone, identify yourself clearly, and honour opt-out requests without delay.

**Can I run the Instagram Profile Email Scraper on a schedule?**
Yes. Apify's scheduler runs any saved input on a recurring basis, which is useful for tracking a niche as new creators emerge. De-duplicate incoming records on `user_id` so repeat discoveries do not clutter your CRM.

**What export formats are supported?**
JSON, CSV, Excel, XML and RSS from the Apify console, plus direct retrieval through the API. Prefer JSON when you want the `emails` array kept as a list; CSV is fine for the flat metric and identity fields.

**Are the extracted email addresses verified?**
No. Addresses are reported exactly as published in the bio. Some will be outdated or mistyped by the account owner. Run any list through an email verification service before a send to protect your sender reputation and reduce bounces.

***

### 🆘 Support & Feedback

If the Instagram Profile Email Scraper behaves unexpectedly — a keyword that returns nothing, malformed records, or country targeting that seems off — please open a report in the **Issues** tab of this Actor and include the exact input JSON you used so it can be reproduced.

Need a custom version? Additional output fields, a different discovery strategy, built-in email verification, or a direct pipeline into your CRM — email **scraperhubapi@gmail.com** with your requirements.

If this Instagram scraper saves you research time, a review on the Actor page is genuinely appreciated, and specific feedback about the fields and filters you need most is what shapes future updates.

***

### ⚖️ Disclaimer

This Instagram Profile Email Scraper collects only publicly available profile information — the same content any visitor can view without logging in. It does not access private accounts, direct messages, stories restricted to followers, or any data behind authentication.

Profile data, biographies and email addresses are personal data. If you process results from this Actor for individuals in the EU, UK or other regulated jurisdictions, you act as the data controller: you must establish a lawful basis under the GDPR or the equivalent local framework, provide the required transparency notice, honour access, rectification and erasure requests, and retain records only as long as your stated purpose requires. Unsolicited commercial email is separately regulated under CAN-SPAM, CASL, the ePrivacy rules and similar regimes, and compliance is your responsibility.

Use of this Actor is also subject to Instagram's Terms of Use and platform policies. Review those terms and take your own legal advice before running large-scale or commercial collection. Nothing in this document constitutes legal advice.

If you believe personal data relating to you has been collected through this Actor and you would like it removed, contact **scraperhubapi@gmail.com** with the relevant details and the request will be handled promptly.

# Actor input Schema

## `keywords` (type: `array`):

List of keywords to search for Instagram profiles (e.g., 'marketing', 'fitness', 'photography'). Each keyword will be searched separately.

## `country` (type: `string`):

Filter results by country. Leave empty for worldwide results.

## `maxLeadsPerKeyword` (type: `integer`):

Maximum number of leads to collect for each keyword (1-500).

## `scrapeLeadsWithEmail` (type: `boolean`):

If enabled, will search for profiles that have emails in their bio (using common email providers like Gmail, Hotmail, Outlook, Yahoo). If disabled, will find all profiles matching keywords.

## Actor input object example

```json
{
  "keywords": [
    "marketing",
    "fitness"
  ],
  "country": "United States",
  "maxLeadsPerKeyword": 20,
  "scrapeLeadsWithEmail": false
}
```

# Actor output Schema

## `results` (type: `string`):

Records scraped by Instagram Profile Email Scraper By Keyword, stored in the run's default dataset.

# 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 = {
    "keywords": [
        "marketing",
        "fitness"
    ],
    "country": "United States",
    "maxLeadsPerKeyword": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapers-hub/instagram-profile-email-scraper-by-keyword").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 = {
    "keywords": [
        "marketing",
        "fitness",
    ],
    "country": "United States",
    "maxLeadsPerKeyword": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("scrapers-hub/instagram-profile-email-scraper-by-keyword").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 '{
  "keywords": [
    "marketing",
    "fitness"
  ],
  "country": "United States",
  "maxLeadsPerKeyword": 20
}' |
apify call scrapers-hub/instagram-profile-email-scraper-by-keyword --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scrapers-hub/instagram-profile-email-scraper-by-keyword"
        }
    }
}

```

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/S71WJtZsyKWsQjaBt/builds/HgznOOVEiUqLq4ue8/openapi.json
