# LinkedIn Sales Navigator Scraper (`hlswh1021/linkedinscraper`) Actor

Extract detailed professional data from LinkedIn Sales Navigator search results. Perfect for lead generation, recruitment, and market research. Scrapes complete profiles including job titles, company details, contact information, and work history.

- **URL**: https://apify.com/hlswh1021/linkedinscraper.md
- **Developed by:** [Liusha Huang](https://apify.com/hlswh1021) (community)
- **Categories:** Developer tools, Automation, AI
- **Stats:** 115 total users, 5 monthly users, 100.0% runs succeeded, 5 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

$50.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 a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

## LinkedIn Sales Navigator Scraper

### 🚀 What This Actor Does

This powerful Apify actor extracts detailed professional data from LinkedIn Sales Navigator search results. It navigates through your Sales Navigator searches and collects comprehensive profile information for lead generation, market research, and recruitment purposes.

#### Key Features:

- **Bulk Profile Extraction**: Scrape hundreds of LinkedIn profiles from Sales Navigator search results
- **Detailed Profile Data**: Extract complete professional information including current position, company details, location, and more. Most scrapers only find the information presented in the sales nav search results. But this scraper will get all the information from the related linkedin profiles.
- **Pagination Support**: Automatically navigates through multiple pages of search results
- **Smart Rate Limiting**: Built-in delays (5-30 seconds) to respect LinkedIn's usage patterns and avoid detection.
- **Cookie-Based Authentication**: Uses your existing Sales Navigator session for authentic access

### ⚡ Get Started

1. Click on "Try for free" button on top of this page
2. Go to [LinkedIn Sales Navigator search page](https://www.linkedin.com/sales/search/people?query=(recentSearchParam%3A(id%3A4656271162%2CdoLogHistory%3Atrue)%2Cfilters%3AList((type%3ACURRENT_COMPANY%2Cvalues%3AList((id%3Aurn%253Ali%253Aorganization%253A1586%2Ctext%3AAmazon%2CselectionType%3AINCLUDED%2Cparent%3A(id%3A0))))%2C(type%3AFUNCTION%2Cvalues%3AList((id%3A8%2Ctext%3AEngineering%2CselectionType%3AINCLUDED)))%2C(type%3ASENIORITY_LEVEL%2Cvalues%3AList((id%3A300%2Ctext%3AVice%2520President%2CselectionType%3AINCLUDED)))))&sessionId=dhKtS7DQR7arBBsac3d8QQ%3D%3D&viewAllFilters=true), search with required filters and once you are done, copy the full URL from address bar and pass it to this actor under the "Sales Navigator URL" parameter
3. Fetch the cookies while you are logged into Sales Navigator. You can use tools like Cookie-Editor to load the entire cookie set of a given page easily. The Apify documentation has a [tutorial on how to do it with screenshots](https://docs.apify.com/tutorials/log-in-by-transferring-cookies#export-your-cookies) - go to the "Export your cookies" section
4. Fill in the Sales Navigator URL and cookies parameters.

### 📥 Input Parameters

| Parameter               | Type    | Required | Description                                       | Default |
| ----------------------- | ------- | -------- | ------------------------------------------------- | ------- |
| `salesNavUrl`           | String  | Yes      | Your LinkedIn Sales Navigator search URL          | -       |
| `cookies`               | Array   | Yes      | LinkedIn authentication cookies from your browser | -       |
| `startPage`             | Integer | No       | Page number to start scraping from                | 1       |
| `maxPages`              | Integer | No       | Maximum number of pages to scrape (1-100)         | 40      |
| `maxResults`            | Integer | No       | Maximum number of profiles to extract (1-300)     | 300     |

#### Example Input:

```json
{
    "salesNavUrl": "https://www.linkedin.com/sales/search/people?query=(recentSearchParam%3A(id%3A123456789))",
    "cookies": [
        {
            "domain": ".linkedin.com",
            "name": "JSESSIONID",
            "value": "ajax:1234567890123456789",
            "path": "/",
            "secure": true,
            "httpOnly": false
        },
        {
            "domain": ".www.linkedin.com",
            "name": "li_at",
            "value": "AQEFARABAAAAABcst3oAAAGYNuqMmQ...",
            "path": "/",
            "secure": true,
            "httpOnly": true
        },
        ...
    ],
    "startPage": 1,
    "maxPages": 10,
    "maxResults": 100
}
````

### 📤 Output Data

Each scraped profile includes:

- **Personal Information**: Full name, profile URL, location, years of experience
- **Current Position**: Job title, company name, tenure, detailed job description
- **Company Details**: Industry, size, location, company logo, LinkedIn company page
- **Experiences**: The working experiences in the past
- **Profile Status**: Premium status, open-to-work indicators, connection degree

#### Output Format:

```json
{
    "type": "profile",
    "page": 1,
    "salesNavLead": {
        "lastName": "Smith",
        "firstName": "John",
        "geoRegion": "San Francisco, CA",
        "currentPositions": [...],
        "companyName": "Tech Corp"
    },
    "linkedInProfileUrl": "https://www.linkedin.com/in/john-smith",
    "profileData": {
        "profile": {...},
        "experience": [...],
        "education": [...]
    },
    "timestamp": "2024-01-15T10:30:00.000Z"
}
```

### 💡 Use Cases

- **Lead Generation**: Build targeted prospect lists for B2B sales teams
- **Recruitment**: Source and analyze potential candidates for hiring
- **Market Research**: Analyze competitor employees and industry talent trends
- **Investment Due Diligence**: Research key personnel at target companies
- **Partnership Development**: Identify decision-makers at potential business partners
- **Sales Intelligence**: Gather comprehensive prospect data for personalized outreach

### 🎯 Perfect For:

- **Sales Teams** looking to scale prospecting efforts
- **Recruiters** building candidate pipelines
- **Market Researchers** analyzing industry trends
- **Business Development** teams finding partnership opportunities
- **Investors** conducting personnel due diligence

### 📧 Need Help? Custom Solutions Available!

This scraper solution is part of the product I have been working on which is an enterprise level solution to help AI/SDRs to collect lead profiles and use AI to prioritize the leads. For example: "here are 1000 linkedin profiles, help me to find the DevOps engineer with at least 3 year experiences with K8s and docker"

So I am definitely the expert in this space and would love to learn your use case if you need help to customize the output.

**Contact me at: hlswh1021@gmail.com**

✅ **I commit to responding within 24 hours** to help you:

- Set up and configure the actor for your specific needs
- Customize data extraction fields
- Integrate with your CRM or database
- Scale for enterprise-level requirements
- Troubleshoot any issues
- Provide bulk processing solutions

Whether you need additional data fields, custom output formats, or help with large-scale operations, I'm here to ensure you get maximum value from this tool.

# Actor input Schema

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

Configure proxy settings. Recommended: Use residential proxies or your own IP for LinkedIn scraping.

## `salesNavUrl` (type: `string`):

LinkedIn Sales Navigator search URL to scrape

## `cookies` (type: `array`):

Array of LinkedIn authentication cookies

## `startPage` (type: `integer`):

Page number to start scraping from the given Sales Nav search result

## `maxPages` (type: `integer`):

Maximum number of pages to scrape from the given Sales Nav search result. Contact me if you need to increase the limit.

## `maxResults` (type: `integer`):

Maximum number of profiles to scrape. Contact me if you need to increase the limit.

## Actor input object example

```json
{
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  },
  "salesNavUrl": "https://www.linkedin.com/sales/search/people?query=(recentSearchParam%3A(id%3A123456789))",
  "startPage": 1,
  "maxPages": 4,
  "maxResults": 100
}
```

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("hlswh1021/linkedinscraper").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 = {}

# Run the Actor and wait for it to finish
run = client.actor("hlswh1021/linkedinscraper").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 '{}' |
apify call hlswh1021/linkedinscraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "LinkedIn Sales Navigator Scraper",
        "description": "Extract detailed professional data from LinkedIn Sales Navigator search results. Perfect for lead generation, recruitment, and market research. Scrapes complete profiles including job titles, company details, contact information, and work history.",
        "version": "1.8",
        "x-build-id": "lv9aITOYPrY0XbFsR"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/hlswh1021~linkedinscraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-hlswh1021-linkedinscraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/hlswh1021~linkedinscraper/runs": {
            "post": {
                "operationId": "runs-sync-hlswh1021-linkedinscraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/hlswh1021~linkedinscraper/run-sync": {
            "post": {
                "operationId": "run-sync-hlswh1021-linkedinscraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "salesNavUrl",
                    "cookies"
                ],
                "properties": {
                    "proxyConfiguration": {
                        "title": "Proxy Configuration",
                        "type": "object",
                        "description": "Configure proxy settings. Recommended: Use residential proxies or your own IP for LinkedIn scraping.",
                        "default": {
                            "useApifyProxy": true,
                            "apifyProxyGroups": [
                                "RESIDENTIAL"
                            ]
                        }
                    },
                    "salesNavUrl": {
                        "title": "Sales Navigator URL",
                        "type": "string",
                        "description": "LinkedIn Sales Navigator search URL to scrape"
                    },
                    "cookies": {
                        "title": "LinkedIn Cookies",
                        "type": "array",
                        "description": "Array of LinkedIn authentication cookies",
                        "items": {
                            "type": "object"
                        }
                    },
                    "startPage": {
                        "title": "Start Page",
                        "minimum": 1,
                        "type": "integer",
                        "description": "Page number to start scraping from the given Sales Nav search result",
                        "default": 1
                    },
                    "maxPages": {
                        "title": "Maximum Pages",
                        "minimum": 1,
                        "maximum": 12,
                        "type": "integer",
                        "description": "Maximum number of pages to scrape from the given Sales Nav search result. Contact me if you need to increase the limit.",
                        "default": 4
                    },
                    "maxResults": {
                        "title": "Maximum Results",
                        "minimum": 1,
                        "maximum": 300,
                        "type": "integer",
                        "description": "Maximum number of profiles to scrape. Contact me if you need to increase the limit.",
                        "default": 100
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
