# LinkedIn Ads Library Scraper — No Login, No Cookies (`logiover/linkedin-ad-library-scraper`) Actor

Scrapes LinkedIn's official Ad Library to extract advertiser names, ad copy, headlines, creative images, video posters, and detail URLs. Filter by keyword (advertiser or ad text), 250+ countries, date range, and creative type. No login, no cookies, no account ban risk. $1.50 per 1,000 ads.

- **URL**: https://apify.com/logiover/linkedin-ad-library-scraper.md
- **Developed by:** [Logiover](https://apify.com/logiover) (community)
- **Categories:** Automation, Developer tools, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $1.50 / 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 Ad Library Scraper — Spy on Competitor Ads | No Login Required

**Extract every public ad from LinkedIn's official Ad Library at scale.** Get advertiser names, ad copy, headlines, creative images, video posters, and detail page URLs — all without login, cookies, or risking your LinkedIn account.

The fastest, cheapest, and most reliable LinkedIn Ad Library scraper on Apify. Built for B2B competitor intelligence, ad creative research, market analysis, and lead generation. **$1.50 per 1,000 ads.** Free 50 ads per run.

---

### 🚀 Why this scraper?

| Feature | This actor | Most competitors |
|---|---|---|
| Login required | ❌ No | ✅ Yes |
| Cookies needed | ❌ No | ✅ Yes |
| Risk of LinkedIn account ban | ❌ None | ⚠️ High |
| Creative type filtering | ✅ 5 types | ❌ None |
| Custom date ranges | ✅ Yes | ⚠️ Preset only |
| Multi-country in one run | ✅ 250+ countries | ⚠️ One at a time |
| Ad detail enrichment | ✅ Optional | ❌ No |
| Pure HTTP (no browser) | ✅ Fast | ❌ Slow Playwright |
| Price per 1,000 ads | **$1.50** | $3–10 |

**Used by:** B2B SaaS marketers, performance marketing agencies, growth teams, sales prospecting tools, market research firms, ad creative studios, competitive intelligence analysts.

---

### 💡 What you can do with this data

#### 1. **B2B Competitor Ad Intelligence**
Track what your competitors are running on LinkedIn — every active and historical ad from the past 12 months. Monitor when rivals launch new campaigns, identify their messaging angles, and spot which creatives they keep running (a strong signal of what's working). Schedule daily runs to catch new ads within hours of going live.

#### 2. **Winning Ad Copy Swipe File**
Build a searchable database of high-performing LinkedIn ad copy in your industry. Filter by keyword (CRM, SaaS, fintech, recruiting, etc.) to see how leading brands write hooks, position offers, and structure CTAs. Train your copywriters on real examples from your category.

#### 3. **Lead Generation by Ad Spend Signal**
Companies running LinkedIn ads have budget. Filter the Ad Library by your target industry keywords and extract advertiser names — every result is a verified active LinkedIn advertiser. Hand the list to SDRs as warm prospects, or feed into your enrichment pipeline.

#### 4. **Creative Format Trend Research**
Are video ads outperforming static images in your vertical this quarter? Filter by creative type (`SPONSORED_VIDEO`, `SPONSORED_STATUS_UPDATE`, `SPONSORED_UPDATE_CAROUSEL`, etc.) and track the format mix over time. Inform your own creative production strategy with category-level data.

#### 5. **Agency Reporting & Pitch Decks**
Pull a competitor's last-30-day ad output and present it as a slide in client pitch decks. "Your competitor ran 47 ads with these 3 messaging themes — here's how we'd outflank them." Concrete data that wins business.

#### 6. **Industry-Wide Benchmarking**
Measure category-level LinkedIn ad activity. Are HR-tech companies advertising more in Q1 than Q4? Is your vertical heating up? Filter by `keyword` (full-text search) and `dateOption` to quantify market activity.

#### 7. **Ad Creative Database for AI/LLM Training**
Building a generative AI tool that writes B2B ad copy? Use this scraper to assemble a clean, structured training dataset of headline + copy + creative type pairs from LinkedIn's transparency archive.

#### 8. **Market Research & Investor Intelligence**
Track which YC, Series A, and Series B companies are spending on LinkedIn. Cross-reference with funding announcements to identify post-raise marketing pushes. Useful for VC scouts, M&A analysts, and growth equity firms.

---

### 📦 Output fields

Every ad record includes:

| Field | Type | Description | Example |
|-------|------|-------------|---------|
| `adId` | string | Unique LinkedIn ad numeric ID | `"1251883283"` |
| `adUrl` | string | LinkedIn detail page URL | `"https://www.linkedin.com/ad-library/detail/1251883283"` |
| `creativeType` | string | Ad format type | `"SPONSORED_STATUS_UPDATE"` |
| `advertiserName` | string | Brand/company running the ad | `"monday CRM"` |
| `advertiserLogoUrl` | string | Advertiser profile image URL | `"https://media.licdn.com/dms/image/..."` |
| `headline` | string | Ad headline (when present) | `"Know what's really happening in your pipeline"` |
| `adCopy` | string | Full ad commentary text | `"Spreadsheets are great for numbers..."` |
| `creativeImageUrl` | string | Main creative image URL | `"https://media.licdn.com/dms/image/..."` |
| `videoPosterUrl` | string | Video thumbnail URL (video ads) | `"https://media.licdn.com/.../videocover-high/..."` |
| `ariaLabel` | string | Semantic ad label (advertiser, format, action) | `"monday CRM, Single Image Ad, View details"` |
| `ctaUrl` | string | Click-through landing URL (detail mode) | `"https://lnkd.in/..."` |
| `detailFields` | object | Extra label/value pairs from detail page | `{ "Impressions": "10K-50K" }` |
| `detailDates` | array | Active dates from detail page | `["2025-03-01", "2025-04-15"]` |
| `searchKeyword` | string | Echo of input keyword | `"saas"` |
| `searchKeywordType` | string | `accountOwner` or `keyword` | `"accountOwner"` |
| `searchCountries` | array | Countries filter used | `["US", "GB"]` |
| `scrapedAt` | string | ISO timestamp of scrape | `"2026-05-07T12:00:00.000Z"` |

#### Creative types supported

| Code | Description | Use case |
|------|-------------|----------|
| `SPONSORED_STATUS_UPDATE` | Single image post | Most common B2B format |
| `SPONSORED_VIDEO` | Video ad | High-engagement creative |
| `SPONSORED_UPDATE_LINKEDIN_ARTICLE` | LinkedIn article promotion | Thought leadership ads |
| `SPONSORED_UPDATE_EVENT` | Event registration ad | Webinars, conferences |
| `SPONSORED_UPDATE_CAROUSEL` | Multi-card carousel | Product showcases |

---

### ⚙️ Input configuration

| Field | Type | Default | Description |
|-------|------|---------|-------------|
| `keyword` | string | `""` | Search term — advertiser brand name OR ad copy text. Empty = browse all ads in selected countries. |
| `keywordType` | string | `"accountOwner"` | `"accountOwner"` searches advertiser names. `"keyword"` searches ad copy/headlines. |
| `countries` | array | `["US"]` | ISO 3166-1 alpha-2 country codes. 250+ supported. Multiple countries combined. |
| `dateOption` | string | `"last-year"` | `current-month`, `last-30-days`, or `last-year`. Ignored if `startDate` is set. |
| `startDate` | string | `null` | Custom range start, YYYY-MM-DD format. Overrides `dateOption`. |
| `endDate` | string | `null` | Custom range end, YYYY-MM-DD format. |
| `creativeTypes` | array | `[]` | Filter ad formats. Empty = all formats. |
| `maxResults` | integer | `1000` | Hard cap on ads scraped. `0` = unlimited. |
| `fetchAdDetails` | boolean | `false` | Fetch each ad's detail page for impressions, payer, CTA URL. Slower, doubles cost. |

---

### 💡 Example inputs

#### Track a specific competitor's current campaigns
```json
{
  "keyword": "monday",
  "keywordType": "accountOwner",
  "countries": ["US"],
  "dateOption": "current-month",
  "maxResults": 200
}
````

#### Industry-wide CRM ad research across Europe

```json
{
  "keyword": "crm software",
  "keywordType": "keyword",
  "countries": ["GB", "DE", "FR", "NL", "IE"],
  "dateOption": "last-year",
  "maxResults": 1000
}
```

#### Video ads only with full detail enrichment

```json
{
  "keyword": "saas",
  "keywordType": "accountOwner",
  "countries": ["US"],
  "creativeTypes": ["SPONSORED_VIDEO"],
  "fetchAdDetails": true,
  "maxResults": 100
}
```

#### Custom date range for campaign analysis

```json
{
  "keyword": "salesforce",
  "keywordType": "accountOwner",
  "countries": ["US"],
  "startDate": "2025-01-01",
  "endDate": "2025-06-30",
  "maxResults": 500
}
```

#### Multi-country B2B SaaS ad sweep

```json
{
  "keyword": "saas",
  "keywordType": "keyword",
  "countries": ["US", "GB", "CA", "AU", "DE"],
  "creativeTypes": ["SPONSORED_STATUS_UPDATE", "SPONSORED_VIDEO"],
  "dateOption": "last-30-days",
  "maxResults": 2000
}
```

#### Build a swipe file of recruiting/HR ads

```json
{
  "keyword": "hiring",
  "keywordType": "keyword",
  "countries": ["US"],
  "dateOption": "last-30-days",
  "maxResults": 500
}
```

***

### 📊 Output sample

```json
{
  "adId": "1251883283",
  "adUrl": "https://www.linkedin.com/ad-library/detail/1251883283",
  "creativeType": "SPONSORED_STATUS_UPDATE",
  "advertiserName": "monday CRM",
  "advertiserLogoUrl": "https://media.licdn.com/dms/image/v2/.../mondaycrm_logo",
  "headline": "Know what's really happening in your pipeline",
  "adCopy": "Spreadsheets are great for numbers; not for knowing what's actually happening in your pipeline. But with monday CRM, your team gets real-time visibility...",
  "creativeImageUrl": "https://media.licdn.com/dms/image/v2/.../CRM_Dashboard_comp_B_1.gif",
  "videoPosterUrl": null,
  "ariaLabel": "monday CRM, Single Image Ad, View details",
  "ctaUrl": "https://monday.com/crm",
  "detailFields": {
    "Total impressions": "10K-50K",
    "First shown": "2025-12-26",
    "Last shown": "2026-05-07"
  },
  "detailDates": ["2025-12-26", "2026-05-07"],
  "searchKeyword": "monday",
  "searchKeywordType": "accountOwner",
  "searchCountries": ["US"],
  "scrapedAt": "2026-05-07T12:00:00.000Z"
}
```

***

### 💰 Pricing

Pay-per-event model. **Pay only for ads you actually receive — no surprises, no per-run charges, no failed-run costs.**

| Volume | Estimated cost |
|--------|---------------|
| 50 ads | **FREE** (every run) |
| 100 ads | $0.075 |
| 500 ads | $0.675 |
| 1,000 ads | $1.50 |
| 5,000 ads | $7.50 |
| 10,000 ads | $15.00 |
| 50,000 ads | $75.00 |

| Subscription tier | Effective price per 1,000 ads |
|---|---|
| Free / Starter | $1.50 |
| Bronze | $1.35 |
| Silver | $1.20 |
| Gold | $1.00 |

**With `fetchAdDetails` enabled**, an additional charge per detail-page fetched applies (richer data: impressions range, payer info, CTA URL, active dates). Use this only when you need the deeper fields — it doubles cost and run time.

***

### ⚡ Performance

- **Pure HTTP, no browser** — server-rendered HTML parsed with Cheerio. 10× faster than Playwright-based scrapers.
- **No cookies, no login, no API key** — uses LinkedIn's official public Ad Library transparency endpoints.
- **No proxy required** for most workloads — Apify Datacenter proxy is sufficient. Add Residential only at very high volume.
- **24 ads per page**, cursor-based pagination via LinkedIn's official `paginationToken`.
- **Throughput**: ~2,000–4,000 ads per minute under normal load.
- **Anti-block**: realistic browser headers, polite request spacing, automatic 429/403 detection with friendly error messages.

***

### 🔗 Integrations

Export results as **JSON**, **CSV**, **Excel**, or **XML**. Stream into your workflow via:

- **Zapier** — alert on new competitor ads in your Slack
- **Make (Integromat)** — auto-add new ads to a Google Sheet swipe file
- **n8n** — build an end-to-end ad-monitoring → AI-summarization → CRM pipeline
- **Webhooks** — push every new ad to your own backend
- **REST API** — programmatic access from Python, Node.js, any language
- **Airtable / Notion** — visual ad library for creative teams
- **LangChain / LlamaIndex** — feed into RAG pipelines for AI-powered ad analysis
- **Google BigQuery / Snowflake** — long-term analytics warehouse

***

### 🆚 LinkedIn Ad Library Scraper vs alternatives

#### vs LinkedIn's official Ad Library website

The native LinkedIn Ad Library is great for one-off browsing but lacks bulk export, structured data, scheduled monitoring, and API access. This scraper turns the same public data into a queryable, exportable, automatable feed.

#### vs LinkedIn Ads API

LinkedIn's official Ads API requires an approved developer account, OAuth flow, and only returns *your own* ads — useless for competitor research. This scraper uses the public transparency tool and works on any advertiser.

#### vs paid B2B intel tools (SimilarWeb Ads, Adbeat, BigSpy)

Paid competitive ad intel platforms cost $500–5,000/month with seat-based pricing. This actor delivers comparable LinkedIn coverage on pay-per-result pricing — typically 10–50× cheaper for the same data volume.

#### vs other Apify LinkedIn ad scrapers

Most existing alternatives require LinkedIn cookies (account ban risk), use slow Playwright browsers, charge $3–10 per 1K results, and skip multi-country support. This scraper is no-login, pure HTTP, $1.50/1K, supports all 250+ LinkedIn countries.

***

### ❓ Frequently asked questions

#### Does this require a LinkedIn account or login?

**No.** LinkedIn's Ad Library is a public transparency tool. This scraper accesses it anonymously — no cookies, no session, no account required. Your LinkedIn account is never touched.

#### Is this legal? Will I get banned from LinkedIn?

This scraper accesses **only publicly available data** from LinkedIn's official transparency portal — the same data anyone can see in a browser without logging in. LinkedIn maintains this public archive specifically for transparency and research purposes. You're responsible for complying with LinkedIn's Terms of Service and applicable privacy laws (GDPR, CCPA) when processing the scraped data downstream.

#### What's the difference between `accountOwner` and `keyword` search?

- `accountOwner` matches the **advertiser's brand name**. Use this when tracking specific competitors. Example: searching `"monday"` returns all ads run by accounts containing "monday" in their name.
- `keyword` performs **full-text search** across ad copy and headlines. Use this for industry/topic research. Example: searching `"crm software"` returns ads from any advertiser whose ad copy mentions those terms.

#### Can I see paused or stopped ads?

**Yes.** LinkedIn's Ad Library shows all ads from the past 12 months by default, including paused and stopped ones. Use `dateOption: "current-month"` if you only want currently running ads.

#### Why are some fields like impressions or CTA URL empty?

Impressions, payer info, and CTA landing URLs are only available on each ad's detail page. By default, the scraper only fetches search result pages (faster, cheaper). Set `fetchAdDetails: true` to retrieve these additional fields — at the cost of one extra HTTP request per ad.

#### How fresh is the data?

LinkedIn updates the Ad Library **in near real-time**. New ads appear within hours of going live. Stopped ads remain visible for the 12-month transparency window. Schedule this actor to run daily/hourly for up-to-date competitor monitoring.

#### Will this work for non-English ads?

**Yes.** LinkedIn's Ad Library is global. Use the `countries` parameter to target specific markets (Germany, Japan, Brazil, France, etc.). Ad copy is returned in its original language.

#### How many countries are supported?

**250+** countries via ISO 3166-1 alpha-2 codes — every country LinkedIn operates in. You can scrape multiple countries in a single run.

#### What if LinkedIn rate-limits me?

The scraper handles 429 responses gracefully with friendly error messages. For very high-volume runs (10,000+ ads), enable Apify's Residential proxy. For most users, Datacenter proxy is sufficient and free.

#### Does enabling `fetchAdDetails` add the CTA URL?

Yes. The CTA (call-to-action) landing URL is only on the detail page. Enable `fetchAdDetails: true` to capture it for every ad.

#### Can I integrate this with Make / Zapier / n8n?

**Absolutely.** Apify provides native integrations with all major automation platforms. Set up a webhook on run completion, or poll the dataset via the Apify API.

#### Is the output AI-ready / RAG-friendly?

**Yes.** Output is clean structured JSON with consistent field types. Pipe directly into LangChain, LlamaIndex, vector databases, or any LLM application. Each ad is a self-contained document with all metadata.

#### What's the rate of completeness for fields?

- `adId`, `adUrl`, `advertiserName`, `creativeType`: ~99%
- `adCopy`, `creativeImageUrl`: ~95%
- `headline`: ~60% (LinkedIn ads often have copy without a separate headline)
- `videoPosterUrl`: ~95% (only on `SPONSORED_VIDEO` ads)
- `ctaUrl`, `detailFields`: only with `fetchAdDetails: true`

#### Can I scrape ads from a specific company's LinkedIn page?

Yes — set `keywordType: "accountOwner"` and pass the company name as `keyword`. The scraper returns all ads from accounts matching that name. To narrow further, combine with `countries` and date filters.

#### How do I handle duplicate ads across pages?

The scraper automatically deduplicates by `adId` within a single run. If you run the actor multiple times and store results in a long-running database, dedupe on `adId` downstream — LinkedIn ads have stable IDs.

#### Can I monitor competitor ad changes over time?

Yes. Schedule this actor to run daily/weekly with the same input. Compare result sets to detect:

- New ads launched (new `adId` values)
- Ads removed (missing `adId` since last run)
- Creative refreshes (same `adId`, different `creativeImageUrl`)

Use Apify Schedules or external cron tools to automate this.

#### Does it support carousel ads?

**Yes.** Carousel ads are returned with `creativeType: "SPONSORED_UPDATE_CAROUSEL"`. The first carousel card's image is in `creativeImageUrl`. Detail page enrichment (`fetchAdDetails: true`) returns carousel sub-cards in `detailFields`.

#### What about LinkedIn event ads and article promotions?

Both supported:

- Event ads: `creativeType: "SPONSORED_UPDATE_EVENT"` — includes event title in headline, registration link in `ctaUrl` (detail mode)
- Article promotions: `creativeType: "SPONSORED_UPDATE_LINKEDIN_ARTICLE"` — article URL in `ctaUrl` (detail mode)

#### Can I filter ads by impressions or spend?

Not in v1.0. LinkedIn's search API does support impression range filtering (parameters `impressionsMinValue` and `impressionsMaxValue`) — these will be added in v1.1 based on user feedback. Open an Issue on the actor page to request priority.

#### What payment methods does Apify support?

Credit card, invoicing for enterprise, and platform credits. New users get **$5 free credits** monthly — enough to scrape ~3,300 ads for free. No credit card required to start.

***

### ⚖️ Legal & Compliance

This scraper accesses **only publicly available data** from LinkedIn's official Ad Library — a transparency tool that LinkedIn provides to the public for the explicit purpose of research, journalism, and ad accountability. No private user data is accessed. No login or authentication is performed. No internal LinkedIn API is exploited.

That said, **you are responsible** for ensuring your specific use of the scraped data complies with:

- **LinkedIn's Terms of Service**
- **GDPR** (EU/UK) — if processing data on EU/UK individuals, ensure lawful basis for processing
- **CCPA** (California) — if processing CA resident data, comply with consumer rights
- **Local data protection laws** in any jurisdiction where you operate or where data subjects reside
- **Anti-spam laws** — if using extracted advertiser data for outreach, comply with CAN-SPAM, CASL, and equivalent regulations

This scraper is a **general-purpose tool**. The actor author and Apify provide no warranty regarding the legality of any specific use case. When in doubt, consult legal counsel.

**Not affiliated with LinkedIn Corporation.** LinkedIn® is a registered trademark of LinkedIn Corporation. All trademarks belong to their respective owners.

***

### 🛠️ Technical details

- **Endpoints used**: `linkedin.com/ad-library/search`, `linkedin.com/ad-library/searchPaginationFragment`, `linkedin.com/ad-library/detail/{adId}` (optional)
- **Method**: Pure HTTP GET requests, server-rendered HTML responses
- **Parsing**: Cheerio (jQuery-like DOM traversal)
- **Pagination**: Cursor-based via embedded `paginationToken` in `<code id="paginationMetadata">`
- **Authentication**: None. Anonymous public access.
- **Headers**: Realistic Chrome desktop browser fingerprint
- **Concurrency**: Sequential by default to be polite with LinkedIn infrastructure
- **Retry logic**: Automatic with friendly error surfacing for 403 / 429 responses
- **Memory**: Runs comfortably in 256 MB
- **Average ad processing time**: ~50ms per ad (without detail enrichment), ~250ms with details
- **Open source**: Built with Apify SDK + Crawlee + Cheerio

***

### 🚦 Getting started in 30 seconds

1. **Click "Try for free"** on this actor's page
2. **Paste a sample input** (use one of the examples above)
3. **Click "Start"**
4. **Wait ~30 seconds** for the first results
5. **Download** as JSON / CSV / Excel from the Storage tab

No credit card required. First 50 ads per run are always free. Paid usage starts after that, billed monthly via Apify.

***

### 💬 Support & feedback

- **Issues / feature requests**: Open a ticket in the **Issues** tab on this actor's page
- **Questions about pricing or usage**: Apify community Discord or in-app chat
- **Custom scraping needs**: Contact the actor author for tailored solutions
- **General Apify support**: [help.apify.com](https://help.apify.com)

***

### 🔍 Search keywords

LinkedIn ad library scraper, LinkedIn ad spy tool, LinkedIn competitor ads, scrape LinkedIn ads, LinkedIn ad library API, LinkedIn ads transparency, LinkedIn ad creative scraper, LinkedIn ads research, LinkedIn ad copy extractor, LinkedIn B2B ads, LinkedIn ad spend signals, LinkedIn advertiser scraper, LinkedIn paid ads, LinkedIn promoted content scraper, LinkedIn sponsored content extraction, scrape LinkedIn advertisers, LinkedIn marketing intelligence, LinkedIn ad benchmarking, LinkedIn ads competitor analysis, LinkedIn paid social scraper, B2B SaaS ad library, LinkedIn ads database, LinkedIn ads API alternative, LinkedIn ad creative database, LinkedIn ads no login, LinkedIn ads without cookies, LinkedIn ad monitoring, LinkedIn ad tracker, LinkedIn ads competitor spy, LinkedIn ad data export, LinkedIn ads JSON, LinkedIn ads CSV.

***

**Ready to outflank your competitors on LinkedIn?** Hit "Try for free" above. First 50 ads are on us.

# Actor input Schema

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

Term to search the LinkedIn Ad Library for. Examples: 'monday', 'salesforce', 'crm software'. Matched against advertiser names by default — change `keywordType` to 'keyword' to search ad copy text instead. Leave empty to browse all ads in the selected countries.

## `keywordType` (type: `string`):

How the keyword is matched. 'accountOwner' searches advertiser/brand names — best for tracking specific competitors. 'keyword' performs full-text search across ad copy and headlines — best for industry/topic research.

## `countries` (type: `array`):

Filter by countries where the ad was shown. Use ISO 3166-1 alpha-2 codes ('US', 'GB', 'DE', 'FR', 'TR', etc.). LinkedIn supports 250+ countries. Multiple values can be combined. Leave empty for worldwide.

## `dateOption` (type: `string`):

Quick date filter for when ads were active. Ignored if a custom `startDate` is provided. 'current-month' = ads active this month, 'last-30-days' = rolling 30-day window, 'last-year' = ads from the past 12 months.

## `startDate` (type: `string`):

Beginning of custom date range in YYYY-MM-DD format (e.g., '2025-01-01'). When provided, overrides `dateOption`. Pair with `endDate` for a bounded range.

## `endDate` (type: `string`):

End of custom date range in YYYY-MM-DD format (e.g., '2025-12-31'). Used together with `startDate`. If only `startDate` is set, ads up to today are returned.

## `creativeTypes` (type: `array`):

Filter by ad format. Accepted values: 'SPONSORED\_STATUS\_UPDATE' (single image post), 'SPONSORED\_VIDEO' (video ad), 'SPONSORED\_UPDATE\_LINKEDIN\_ARTICLE' (article promotion), 'SPONSORED\_UPDATE\_EVENT' (event ad), 'SPONSORED\_UPDATE\_CAROUSEL' (carousel). Multiple values can be combined. Leave empty for all formats.

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

Maximum number of ads to save to the dataset. The scraper paginates 24 ads per page until this cap is hit or no more pages remain. Set to 0 for unlimited.

## `fetchAdDetails` (type: `boolean`):

When enabled, fetches each ad's detail page (`/ad-library/detail/{id}`) to retrieve impressions range, payer info, CTA URL, and date metadata. Produces richer output but doubles requests and run time.

## Actor input object example

```json
{
  "keyword": "",
  "keywordType": "accountOwner",
  "countries": [
    "US"
  ],
  "dateOption": "last-year",
  "startDate": null,
  "endDate": null,
  "creativeTypes": [],
  "maxResults": 1000,
  "fetchAdDetails": false
}
```

# Actor output Schema

## `adId` (type: `string`):

LinkedIn ad numeric ID

## `adUrl` (type: `string`):

LinkedIn detail page URL

## `advertiserName` (type: `string`):

Company running the ad

## `advertiserLogoUrl` (type: `string`):

Advertiser logo image URL

## `creativeType` (type: `string`):

SPONSORED\_STATUS\_UPDATE, etc.

## `headline` (type: `string`):

Ad headline text

## `adCopy` (type: `string`):

Ad commentary / body text

## `creativeImageUrl` (type: `string`):

Main creative image URL

## `ctaUrl` (type: `string`):

Click-through landing page URL

## `scrapedAt` (type: `string`):

ISO timestamp of scrape

# 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("logiover/linkedin-ad-library-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 = {}

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

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "LinkedIn Ads Library Scraper — No Login, No Cookies",
        "description": "Scrapes LinkedIn's official Ad Library to extract advertiser names, ad copy, headlines, creative images, video posters, and detail URLs. Filter by keyword (advertiser or ad text), 250+ countries, date range, and creative type. No login, no cookies, no account ban risk. $1.50 per 1,000 ads.",
        "version": "0.0",
        "x-build-id": "Lq3iTQxZWrmVUJRR7"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/logiover~linkedin-ad-library-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-logiover-linkedin-ad-library-scraper",
                "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/logiover~linkedin-ad-library-scraper/runs": {
            "post": {
                "operationId": "runs-sync-logiover-linkedin-ad-library-scraper",
                "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/logiover~linkedin-ad-library-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-logiover-linkedin-ad-library-scraper",
                "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",
                "properties": {
                    "keyword": {
                        "title": "Search Keyword",
                        "type": "string",
                        "description": "Term to search the LinkedIn Ad Library for. Examples: 'monday', 'salesforce', 'crm software'. Matched against advertiser names by default — change `keywordType` to 'keyword' to search ad copy text instead. Leave empty to browse all ads in the selected countries.",
                        "default": ""
                    },
                    "keywordType": {
                        "title": "Keyword Search Mode",
                        "enum": [
                            "accountOwner",
                            "keyword"
                        ],
                        "type": "string",
                        "description": "How the keyword is matched. 'accountOwner' searches advertiser/brand names — best for tracking specific competitors. 'keyword' performs full-text search across ad copy and headlines — best for industry/topic research.",
                        "default": "accountOwner"
                    },
                    "countries": {
                        "title": "Countries",
                        "type": "array",
                        "description": "Filter by countries where the ad was shown. Use ISO 3166-1 alpha-2 codes ('US', 'GB', 'DE', 'FR', 'TR', etc.). LinkedIn supports 250+ countries. Multiple values can be combined. Leave empty for worldwide.",
                        "default": [
                            "US"
                        ],
                        "items": {
                            "type": "string"
                        }
                    },
                    "dateOption": {
                        "title": "Date Range Preset",
                        "enum": [
                            "current-month",
                            "last-30-days",
                            "last-year"
                        ],
                        "type": "string",
                        "description": "Quick date filter for when ads were active. Ignored if a custom `startDate` is provided. 'current-month' = ads active this month, 'last-30-days' = rolling 30-day window, 'last-year' = ads from the past 12 months.",
                        "default": "last-year"
                    },
                    "startDate": {
                        "title": "Custom Start Date",
                        "type": "string",
                        "description": "Beginning of custom date range in YYYY-MM-DD format (e.g., '2025-01-01'). When provided, overrides `dateOption`. Pair with `endDate` for a bounded range.",
                        "default": null
                    },
                    "endDate": {
                        "title": "Custom End Date",
                        "type": "string",
                        "description": "End of custom date range in YYYY-MM-DD format (e.g., '2025-12-31'). Used together with `startDate`. If only `startDate` is set, ads up to today are returned.",
                        "default": null
                    },
                    "creativeTypes": {
                        "title": "Creative Type Filter",
                        "type": "array",
                        "description": "Filter by ad format. Accepted values: 'SPONSORED_STATUS_UPDATE' (single image post), 'SPONSORED_VIDEO' (video ad), 'SPONSORED_UPDATE_LINKEDIN_ARTICLE' (article promotion), 'SPONSORED_UPDATE_EVENT' (event ad), 'SPONSORED_UPDATE_CAROUSEL' (carousel). Multiple values can be combined. Leave empty for all formats.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "maxResults": {
                        "title": "Max Results",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Maximum number of ads to save to the dataset. The scraper paginates 24 ads per page until this cap is hit or no more pages remain. Set to 0 for unlimited.",
                        "default": 1000
                    },
                    "fetchAdDetails": {
                        "title": "Fetch Full Ad Details",
                        "type": "boolean",
                        "description": "When enabled, fetches each ad's detail page (`/ad-library/detail/{id}`) to retrieve impressions range, payer info, CTA URL, and date metadata. Produces richer output but doubles requests and run time.",
                        "default": false
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
