LinkedIn Ad Library Scraper
Pricing
from $4.99 / 1,000 results
Go to Apify Store
LinkedIn Ad Library Scraper
A fast, high-performance scraper built for lead generation, competitor analysis, and business intelligence. Extracts detailed business profiles, including name, contact details, emails, phone numbers, location, ratings, and reviews from LinkedIn. Supports custom search URLs, proxy rotation, and p...
Pricing
from $4.99 / 1,000 results
Rating
0.0
(0)
Developer
codingfrontend
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
4 days ago
Last modified
Categories
Share
Apify actor to scrape ad listings from the LinkedIn Ad Library based on search queries.
Features
- Search LinkedIn Ad Library by keyword or advertiser name
- Filter ads by country/region
- Extract advertiser names, ad text, dates, impressions, and media type
- Automatic scrolling to load lazy-loaded results
- Pagination support for multi-page results
- Proxy support (residential proxies recommended)
Input
| Field | Type | Default | Description |
|---|---|---|---|
query | string | "Google" | Keyword or advertiser name to search for |
maxItems | integer | 50 | Maximum number of ad results to scrape (1–5000) |
country | string | "US" | Country code to filter ads by (e.g. US, GB, IN, DE) |
proxyConfiguration | object | Apify Residential | Proxy settings for the scraper |
Example Input
{"query": "Google","maxItems": 10,"country": "US"}
Output
Each scraped ad contains:
| Field | Type | Description |
|---|---|---|
position | integer | Result position index |
advertiserName | string | Name of the advertiser |
adText | string | Text content of the ad |
startDate | string | Date the ad started running |
endDate | string | Date the ad stopped running |
impressions | string | Impression count or range |
link | string | URL to the ad entry in LinkedIn Ad Library |
mediaType | string | Type of ad creative (Text, Image, Video) |
query | string | The search query used |
country | string | The country filter used |
scrapedAt | string | ISO timestamp of when the data was scraped |
Example Output
{"position": 1,"advertiserName": "Google","adText": "Build what's next with Google Cloud. Get started free.","startDate": "Jan 2025","endDate": "","impressions": "100K-500K","link": "https://www.linkedin.com/ad-library/detail/12345","mediaType": "Image","query": "Google","country": "US","scrapedAt": "2025-01-25T10:30:00.000Z"}
Usage
Apify Console
- Go to the actor's page on Apify Console
- Set the input parameters
- Click "Start"
API
import { ApifyClient } from 'apify-client';const client = new ApifyClient({ token: 'YOUR_TOKEN' });const run = await client.actor('your-username/linkedin-ad-library-scraper').call({query: 'Google',maxItems: 50,country: 'US',});const { items } = await client.dataset(run.defaultDatasetId).listItems();console.log(items);
Local Development
npm installnpm start
Project Structure
src/├── main.js # Actor entry point — reads input, configures crawler├── constants.js # Shared constants (URLs, scroll limits)├── routes.js # Crawler route handlers (SEARCH)└── utils/└── extraction.js # Ad data extraction from page DOM