# YouTube Search Scraper & API: Videos, Channels, Playlists (`s_actors/youtube-search-scraper`) Actor

Scrape YouTube search results for any keyword: videos, Shorts, channels and playlists with every YouTube filter, newest first (YouTube dropped that sort), without Shorts on request, by country. Exact views, dates, channels. A YouTube Data API alternative without quota or key.

- **URL**: https://apify.com/s_actors/youtube-search-scraper.md
- **Developed by:** [Superior Actors](https://apify.com/s_actors) (community)
- **Categories:** Videos, Social media, AI
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.18 / 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.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### YouTube Search Scraper & API: Videos, Channels, Playlists

Scrape **YouTube search results** for any keyword: **videos, Shorts, channels and playlists** with every YouTube filter (upload date, duration, 4K, live, subtitles...), in any **country**. Get the latest uploads **newest first** (YouTube removed that sort; the Actor brings it back), **drop Shorts** from video results, and schedule **Only new results** for alerts about your brand or topic.

```json
{ "searchQueries": ["iphone 17 review"], "maxResults": 50, "excludeShorts": true }
```

A **YouTube Data API alternative**: no API key, no daily quota, no login. Use it as a **YouTube search API**: one call returns clean JSON.

#### What you get

One row per result. Real example, September 2026, "iphone 17 review":

| rank | title | channel | views | published | length |
|---|---|---|---|---|---|
| 1 | iPhone 18 Pro vs iPhone 17 - DON'T BE FOOLED! | GregsGadgets | 52,799 | 15 hours ago | 18:15 |
| 2 | iPhone 17 Review: No Asterisks! | Marques Brownlee | 6,837,728 | 11 months ago | 11:20 |
| 3 | iPhone 17 - 1 Year Later Review | Nick Ackerman | 104,820 | 3 weeks ago | 15:23 |

| Field | Description |
|---|---|
| `query`, `rank`, `country`, `searchUrl` | The search and the position of the result |
| `type` | `video`, `short`, `channel` or `playlist` |
| `title`, `url`, `videoId`, `thumbnail`, `snippet`, `badges` | The result as shown in search (badges: 4K, CC, New...) |
| `views`, `publishedText`, `publishedDate`, `durationSeconds`, `isLive` | Exact views, upload date (approximate from "3 weeks ago") and length |
| `channelName`, `channelHandle`, `channelId`, `channelUrl` | Who uploaded it |
| `likes`, `comments`, `description`, `channelSubscribers` | With **Exact video details**: exact date too |
| `channelSubscribers`, `isVerified`, `isArtist` | Channel results |
| `playlistId`, `videosCount`, `isMix` | Playlist results |

#### How it works

1. Add **search queries**, one per line
2. Pick the **Result type** (videos, Shorts, channels, playlists or everything) and the filters you need
3. Run, then download as JSON, CSV or Excel, or call it as an API

| Input | What it does |
|---|---|
| **Sort by** | Relevance, popularity (most viewed) or **newest first** |
| **Upload date** | Last hour, today, this week, this month, this year |
| **Duration** | Under 4 minutes, 4-20 minutes, over 20 minutes |
| **Features** | Live, 4K, HD, subtitles, Creative Commons, 360°, VR180, 3D, HDR, location, purchased |
| **Exclude Shorts** | Only regular videos, no Shorts in the results |
| **Minimum views** | Only videos above a view count |
| **Country** | Results as YouTube shows them in that country |
| **Only new results** | Monitoring: later runs return only new videos for the keyword |

#### Why this Actor

| | |
|---|---|
| 🕒 **Newest first** | YouTube dropped sorting by upload date; the Actor reads more results and sorts them by upload time |
| 🚫 **No Shorts** | Search results full of Shorts? One switch keeps only real videos |
| 🧰 **Every filter works** | Upload date, duration, features, type, country; Shorts searches with date or popularity filters too |
| 🔔 **Keyword alerts** | Only new videos about your brand, product or topic on every scheduled run |
| 🔑 **No API quota** | The YouTube Data API allows ~100 searches a day per key; here there is no limit |
| 💰 **$0.23 per 1,000 results** | Removed results are free; the most used YouTube scraper charges $4 per 1,000 |

#### Only new results: alerts for a keyword

1. Add your brand, product or topic, set **Upload date: This week**, switch on **Only new results**, give the task a **Monitor name**
2. Save as a task and schedule it, e.g. every morning
3. **First run** returns the results and remembers the top 100. **Every later run** returns only videos that were not there before and were published since the last run

Send them to Slack, email or [Google Sheets](https://apify.com/s_actors/google-sheets-import-export) with an integration.

#### Pricing

Pay per result, no subscription needed. Apify Scale and Business plans pay less:

| Event | Free and Starter plans | Scale plan | Business plan |
|---|---|---|---|
| Run start | $0.001 | $0.001 | $0.001 |
| Result (video, Short, channel or playlist) | $0.000225 | $0.000202 | $0.00018 |

| Task | Cost |
|---|---|
| Top 50 videos for a keyword | $0.012 |
| 10 keywords × 100 results | $0.23 |
| Daily alerts for 5 keywords for a month (~3 new videos a day each) | ~$0.13 per month |

#### Ready-made tasks

Open it, change the keywords, and run:

| Task | What you get |
|---|---|
| [YouTube Search Scraper: Export Search Results to CSV](https://apify.com/s_actors/youtube-search-scraper/examples/youtube-search-results-export) | Results of any keyword |

#### FAQ

**Why is "newest first" slower?** YouTube no longer sorts search results by date, so the Actor reads three times Max results and sorts them itself. With **Upload date** set, the newest uploads are all among them.

**How many results can I get?** YouTube lists about 500-700 results for a query; ask for up to 1,000.

**Are the dates exact?** Search shows "3 weeks ago"; `publishedDate` is computed from it. Turn on **Exact video details** for the exact date.

**Is it the same as the YouTube Data API search?** Same kind of data, without the API key, the 10,000-unit daily quota (100 searches) and the approval process, and with the Shorts and newest-first options the API does not have.

#### Use with the API and AI agents

Run it via the [Apify API](https://docs.apify.com/api/v2) from Python, Node.js or any HTTP client, or connect it to Claude, ChatGPT and other AI agents through the [Apify MCP server](https://mcp.apify.com): "Find this week's most viewed videos about the Pixel 11 and tell me what reviewers complain about."

#### Other YouTube tools

| Tool | What it does |
|---|---|
| [YouTube Trending & Charts Scraper](https://apify.com/s_actors/youtube-trending-scraper) | Trending music videos and trailers, top songs, artists, Shorts songs, podcasts by country, chart history |
| [YouTube Thumbnail Downloader](https://apify.com/s_actors/youtube-thumbnail-downloader) | Thumbnails of videos, channels and searches in HD, ZIP, thumbnail change history |
| [YouTube Playlist Scraper](https://apify.com/s_actors/youtube-playlist-scraper) | Every video of playlists to CSV, length at any speed, deleted video finder |
| [YouTube Channel Scraper](https://apify.com/s_actors/youtube-channel-scraper) | Channel stats, growth history, videos, Shorts and streams |
| [YouTube Channel Email Scraper](https://apify.com/s_actors/youtube-channel-email-scraper) | Public emails, websites and socials of channels, influencer lists by niche |
| [YouTube Video Details Scraper](https://apify.com/s_actors/youtube-video-details-scraper) | Full details and exact stats of any videos, views tracker over time |
| [YouTube Shorts Scraper](https://apify.com/s_actors/youtube-shorts-scraper) | Shorts of channels, searches, hashtags and sounds: exact stats, viral score |
| [YouTube Transcript Scraper](https://apify.com/s_actors/youtube-transcript-scraper) | Transcripts and subtitles of videos, channels and playlists: text, SRT, search |
| [YouTube Comments Scraper](https://apify.com/s_actors/youtube-comments-scraper) | Comments and replies of videos, Shorts and channels, only-new monitoring |
| [YouTube SEO & Rank Tracker](https://apify.com/s_actors/youtube-seo-rank-tracker) | Searches a video ranks for, keyword rankings, tags, suggestions |
| [Google Sheets Import & Export](https://apify.com/s_actors/google-sheets-import-export) | Send the results to a Google Sheet |

#### Is it legal?

The Actor reads only public search results that YouTube shows to any visitor, without logging in, and does not download videos. Use it for research, analytics and monitoring.

# Actor input Schema

## `searchQueries` (type: `array`):

Keywords to search on YouTube, one per line, exactly as you would type them.

## `resultType` (type: `string`):

What to search for, like the Type filter on YouTube.

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

How many results to return per query. YouTube lists up to about 500-700 for a query.

## `sortBy` (type: `string`):

YouTube removed sorting by upload date. Newest first reads three times more results (videos and Shorts) and sorts them by upload time; combine it with Upload date for the latest uploads.

## `uploadDate` (type: `string`):

Only videos uploaded in this period. Older videos that YouTube mixes in are removed.

## `duration` (type: `string`):

Video length, as the YouTube filter.

## `features` (type: `array`):

Only videos with all of these features, as the YouTube filters.

## `excludeShorts` (type: `boolean`):

Drop Shorts from video results: only regular videos. Skipped Shorts are free.

## `minViews` (type: `integer`):

Only videos with at least this many views. Skipped videos are free.

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

Two-letter country the search runs from (us, gb, de, in, br...): results differ by country.

## `videoDetails` (type: `boolean`):

Open every video for likes, comment count, exact publish date, full description and channel subscribers. Slower, same price.

## `onlyNew` (type: `boolean`):

For scheduled runs. The first run returns the results and remembers the top 100; later runs return only videos that were not there before and were published since the previous run. Best with Upload date: This week.

## `monitorName` (type: `string`):

Name of the memory used by Only new results. Use a different name for each task.

## `maxConcurrency` (type: `integer`):

How many requests to YouTube run at the same time.

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

Requests go direct first and switch to Apify datacenter proxies when YouTube refuses them. The default works for most runs.

## Actor input object example

```json
{
  "searchQueries": [
    "iphone 17 review"
  ],
  "resultType": "videos",
  "maxResults": 20,
  "sortBy": "relevance",
  "uploadDate": "any",
  "duration": "any",
  "excludeShorts": false,
  "country": "us",
  "videoDetails": false,
  "onlyNew": false,
  "monitorName": "default",
  "maxConcurrency": 10,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

Rank, title, views, date, length and channel of each result.

## `all` (type: `string`):

Every field of every row.

# 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 = {
    "searchQueries": [
        "iphone 17 review"
    ],
    "maxResults": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("s_actors/youtube-search-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 = {
    "searchQueries": ["iphone 17 review"],
    "maxResults": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("s_actors/youtube-search-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "searchQueries": [
    "iphone 17 review"
  ],
  "maxResults": 20
}' |
apify call s_actors/youtube-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,s_actors/youtube-search-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/jX4X05WGJdbp2q3pt/builds/JjumZUgqVkCE8NVEb/openapi.json
