# YouTube Scraper — Videos, Channels & Search, Cheap (No API Key) (`fabrikit/youtube-videos-scraper`) Actor

YouTube scraper for search results, channels, playlists and single videos: title, views, publish date, duration, thumbnail, channel info, plus optional details (full description, likes, category, tags, chapters). No API key, no login, no comments. Pay per result, no subscription.

- **URL**: https://apify.com/fabrikit/youtube-videos-scraper.md
- **Developed by:** [Fabrikit](https://apify.com/fabrikit) (community)
- **Categories:** Social media, AI, SEO tools
- **Stats:** 3 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.50 / 1,000 video 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/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 Scraper — Videos, Channels & Search, Cheap (No API Key)

Scrape public YouTube data without an API key, a login or a browser: **search results, channel videos, Shorts, live streams, playlists and single videos**, plus **channel profiles**. Fast HTTP-only runs, tiny memory footprint, and a built-in proxy ladder (datacenter first, residential only if YouTube blocks).

**No comments and no commenter data are collected.** Only public video and channel metadata.

### What you get

- **Search**: any keyword, with upload-date, length, sort-order and feature filters (HD, 4K, live, subtitles, Creative Commons...).
- **Channels**: paste a `@handle`, `/channel/UC...` or `/c/...` URL to list the channel's videos (optionally Shorts and past live streams) and get one channel profile record.
- **Playlists**: every video of a public playlist.
- **Single videos**: paste any watch / youtu.be / Shorts URL.
- **Video details (optional add-on)**: full description, exact like count, exact view count, category, tags, chapters, exact upload timestamp.

### Who it is for

- **Content creators and YouTube strategists** researching which titles, lengths and topics get views in a niche.
- **Marketing and influencer teams** building lists of channels with subscriber counts, video counts, country and public links.
- **SEO teams** studying titles, tags and chapters that rank for a keyword.
- **Brands and agencies** tracking competitors' channels and new uploads on a schedule.
- **Data and AI teams** building video metadata datasets without YouTube API quotas.

### How to scrape YouTube without the API

1. Add **search queries**, or paste **URLs**: channels (`@handle`, `/channel/UC…`, `/c/…`), channel tabs, playlists, search pages, single videos or Shorts.
2. For searches, choose **sort order**, **upload date**, **duration** and **features** (HD, 4K, live, subtitles, Creative Commons…).
3. For channels, decide whether to include **Shorts** and **past live streams**, and whether to save a **channel profile** record.
4. Turn on **video details** if you need full descriptions, exact likes and views, category, tags, chapters and exact upload dates.
5. Set **maxResultsPerQuery** and **maxItems**, run, and export as JSON, CSV or Excel.

### Input examples

Search with filters:

```json
{
  "searchQueries": ["react tutorial", "python for beginners"],
  "maxResultsPerQuery": 100,
  "maxItems": 200,
  "uploadDate": "month",
  "duration": "long",
  "sortBy": "views"
}
```

Channel + playlist + one video, with details:

```json
{
  "startUrls": [
    { "url": "https://www.youtube.com/@LofiGirl" },
    { "url": "https://www.youtube.com/playlist?list=PLFgquLnL59alCl_2TQvOiD5Vgm1hCaGSI" },
    { "url": "https://youtu.be/dQw4w9WgXcQ" }
  ],
  "maxResultsPerQuery": 50,
  "includeShorts": true,
  "includeVideoDetails": true
}
```

Most viewed first, uploaded this month (the "Most viewed AI tutorials this month" example task):

```json
{ "searchQueries": ["ai tutorial"], "sortBy": "views", "uploadDate": "month", "maxItems": 50, "maxResultsPerQuery": 50 }
```

Spanish-language recipe videos for Mexico (the "Videos de recetas en español" task):

```json
{ "searchQueries": ["recetas fáciles"], "language": "es", "region": "MX", "maxItems": 50, "maxResultsPerQuery": 50 }
```

| Field | Meaning |
|---|---|
| `searchQueries` | Keywords to search (one list entry each). |
| `startUrls` | Video, Shorts, channel, channel tab, playlist or search-results URLs. Bare `@handle` entries work too. |
| `maxItems` | Hard cap on videos saved in the whole run (default 50). Channel profile records are extra. |
| `maxResultsPerQuery` | Videos per query / channel / playlist (default 50). |
| `sortBy`, `uploadDate`, `duration`, `features` | Search filters. |
| `includeShorts` | Search: keep Shorts. Channels: also read the Shorts tab. |
| `includeStreams` | Channels: also read the live / past streams tab. |
| `includeChannelInfo` | Save one channel profile record per channel URL (default on). |
| `includeVideoDetails` | Add-on: description, likes, category, tags, chapters, exact dates. |
| `language`, `region` | `hl` / `gl` sent to YouTube. |
| `proxyConfiguration` | Starts on Apify datacenter proxy, falls back to residential automatically. |

### Output

Video record:

```json
{
  "type": "video",
  "videoId": "Fxqv9xdLMG4",
  "url": "https://www.youtube.com/watch?v=Fxqv9xdLMG4",
  "title": "Journey Through Time - Ancient China [lofi beats to celebrate Chinese New Year]",
  "channelName": "Lofi Girl",
  "channelId": "UCSJ4gkVC6NrvII8umztf0Ow",
  "channelUrl": "https://www.youtube.com/@LofiGirl",
  "viewCount": 346101,
  "publishedText": "8 months ago",
  "publishedAt": "2026-02-10T09:00:06-08:00",
  "duration": "1:00:40",
  "durationSeconds": 3640,
  "thumbnail": "https://i.ytimg.com/vi/Fxqv9xdLMG4/hq720.jpg",
  "isShort": false,
  "isLive": false,
  "isUpcoming": false,
  "badges": [],
  "searchQuery": null,
  "inputUrl": "https://www.youtube.com/@LofiGirl",
  "description": "Start the Chinese New Year with calming lofi...",
  "likeCount": 9056,
  "category": "Music",
  "keywords": ["lofi", "chinese new year"],
  "chapters": [{ "title": "Intro", "startSeconds": 0 }],
  "uploadDate": "2026-02-10T09:00:06-08:00"
}
```

Without `includeVideoDetails`, the detail fields (`description`, `likeCount`, `category`, `keywords`, `chapters`, `uploadDate`) are `null`, and `publishedAt` is derived from the relative text ("8 months ago" becomes a date at day precision). With details it is the exact upload timestamp.

Channel record (`"type": "channel"`): `channelId`, `name`, `handle`, `url`, `subscriberCount` (YouTube rounds it, e.g. 15.8M), `subscriberCountText`, `videoCount`, `totalViews`, `description`, `country`, `joinedDate`, `links` (the channel's own public links), `avatar`, `isVerified`, `keywords`.

Notes: Shorts from search or channel tabs show only title and views until you enable details (YouTube does not list their duration or date in the feed). The same video is saved once per run even if several queries find it.

#### Output fields

| Field | Record | Description |
|---|---|---|
| `type` | both | `video` or `channel`. |
| `videoId` / `url` / `title` | video | Video id, watch URL and title. |
| `channelName` / `channelId` / `channelUrl` | video | Channel that published the video. |
| `viewCount` | video | Views (exact with details). |
| `publishedText` / `publishedAt` | video | Relative text ("8 months ago") and a date derived from it (exact with details). |
| `duration` / `durationSeconds` | video | Length as text and in seconds. |
| `thumbnail` | video | Thumbnail URL. |
| `isShort` / `isLive` / `isUpcoming` / `badges` | video | Shorts, live and upcoming flags; YouTube badges. |
| `descriptionSnippet` | video | Short description text from search results, when shown. |
| `searchQuery` / `inputUrl` | video | The query or URL that found the video. |
| `description` / `likeCount` / `category` / `keywords` / `chapters` / `uploadDate` | video | Detail add-on fields. |
| `name` / `handle` / `url` | channel | Channel name, @handle and URL. |
| `subscriberCount` / `subscriberCountText` | channel | Subscribers (rounded by YouTube) and the original text. |
| `videoCount` / `totalViews` | channel | Number of videos and total views. |
| `description` / `country` / `joinedDate` / `links` | channel | About-page information. |
| `avatar` / `isVerified` / `keywords` | channel | Profile image, verification badge and channel keywords. |
| `scrapedAt` | both | When the record was collected. |

### How much does it cost to scrape YouTube?

| Event | When it is charged |
|---|---|
| `video-result` | Each video saved |
| `video-details` | Add-on, per video enriched with details |
| `channel-result` | Each channel profile saved |
| `apify-actor-start` | Once per run (a fraction of a cent) |

From 30 October 2026, 1,000 videos cost US$3 on the Apify Free plan; paid Apify plans pay less per video — see the **Pricing** tab. Video details add US$1 per 1,000 videos and channel profiles cost US$1.50 per 1,000 on every plan, so 1,000 videos with full details cost US$4 on the Free plan. You can cap spending with Apify's "maximum cost per run": the Actor stops cleanly when the limit is reached.

### FAQ

**Do I need a YouTube API key?** No. No key, no OAuth and no quota.

**Does it need a login or cookies?** No, only public data.

**Does it scrape comments?** No. Comments and commenter data are deliberately not collected.

**How many results can one search return?** YouTube serves roughly 20 results per page and keeps paging for hundreds of results per query; split very broad topics into several queries for more coverage.

**Why are subscriber counts rounded?** YouTube only publishes rounded subscriber counts for public channels.

**Will it get blocked?** Requests start on Apify datacenter proxies. If YouTube answers with a block or bot check twice in a row, the run switches to residential proxies automatically and logs it. Video details use an extra bot-checked endpoint that is retried on fresh IPs; if it still fails for a video, the rest of the details (description, likes, chapters, upload date) are returned and `category` / `keywords` stay empty.

**Which languages work?** Any `language` / `region` pair is accepted; view and subscriber counts are parsed most reliably in English.

**What happens if a run finds nothing?** It fails with the reason (for example, an invalid channel URL or YouTube returning nothing), so you are not charged for results and scheduled monitors do not silently report zero.

**Can I monitor a channel's new uploads?** Yes. Save the channel URL as a task with a small `maxResultsPerQuery` (the Videos tab lists newest first) and schedule it daily; compare `videoId` across runs.

**Does it download videos or transcripts?** No. It only returns metadata. It does not download video files.

### Use cases

Content research and trend monitoring, competitor and influencer lists, SEO keyword and title research, dataset building for AI/ML (titles, tags, chapters), channel growth tracking, and feeding BI dashboards or automations (Make, n8n, Zapier) through the Apify API.

### Is it legal to scrape YouTube?

This actor only collects public video and channel metadata that YouTube shows to any visitor, without logging in, and it deliberately does not collect comments or commenter data. Channel names, handles, descriptions and links can still be personal data when a channel belongs to an individual, so laws such as the EU GDPR, Chile's Ley 21.719 or the California CCPA may apply to how you store and use them; you are responsible for a lawful purpose. Videos, thumbnails and descriptions are the creators' content, so respect copyright and YouTube's terms of service. This is general information, not legal advice.

### Integrations

Run the YouTube Scraper from the Apify API or the JavaScript and Python clients, trigger follow-up steps with webhooks, or schedule channel and keyword checks in Apify Console. It works with n8n, Make and Zapier, and with LangChain and LlamaIndex through their Apify integrations. AI agents in Claude, ChatGPT, Cursor and other MCP clients can find and run it through Apify's MCP server. Export as JSON, CSV or Excel, or read from the dataset API.

### Use with AI agents

Use this actor to get public YouTube video metadata for search keywords, channels, playlists or video URLs, plus channel profiles, without a YouTube API key.

```json
{ "searchQueries": ["home espresso review"], "sortBy": "views", "maxItems": 20 }
```

Main output fields: `title`, `url`, `channelName`, `viewCount`, `publishedAt`, `durationSeconds`, `isShort`; with details `description`, `likeCount`, `keywords`, `chapters`; channel records `name`, `handle`, `subscriberCount`, `videoCount`. It is pay-per-event: an agent pays a small start fee plus a fixed price per video (and per detail or channel record), not for compute time.

### Related actors

- [Bilibili Scraper](https://apify.com/fabrikit/bilibili-video-scraper) — the same kind of video data from China's Bilibili.
- [Google Trends Scraper](https://apify.com/fabrikit/google-trends-scraper) — YouTube search interest over time (`property: youtube`).
- [Google News Scraper](https://apify.com/fabrikit/google-news-scraper) — news coverage of the topics and creators you track.
- [Google Ads Transparency Scraper](https://apify.com/fabrikit/google-ads-transparency-scraper) — a brand's Google ads, including video ads.

#### Ready-made examples

- [Most viewed AI tutorials this month](https://apify.com/fabrikit/youtube-videos-scraper/examples/most-viewed-ai-tutorials)
- [Videos de recetas en español](https://apify.com/fabrikit/youtube-videos-scraper/examples/recetas-videos-espanol)

### Changelog

- **2026-10-16** — README expanded: how-to, more input examples, output field table, FAQ, legal notes, integrations and example tasks.
- **2026-10-15** — Tiered pricing announced, effective 2026-10-30 (lower per-video price on paid Apify plans).
- **2026-10-13** — Builds 0.1.1–0.1.8: initial release with search, channels (videos, Shorts, streams), playlists, single videos, channel profiles and the video-details add-on; retries on fresh IPs for the bot-checked details endpoint; default memory 512 MB.

### En español

Extrae datos públicos de YouTube sin API key ni login: resultados de búsqueda (con filtros de fecha, duración y orden), videos de canales, Shorts, directos, listas de reproducción y videos individuales, más el perfil del canal (suscriptores, videos, vistas totales, país, enlaces). Con `includeVideoDetails` agrega descripción completa, likes, categoría, etiquetas, capítulos y fecha exacta. No recolecta comentarios. Se cobra por video guardado, con extras opcionales por detalles y por perfil de canal; el precio vigente para tu plan está en la pestaña Pricing. Usa proxy datacenter de Apify y cambia a residencial automáticamente si YouTube bloquea.

# Actor input Schema

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

Keywords to search on YouTube, one per entry (e.g. `lofi hip hop`, `react tutorial 2026`). Each query returns up to *Max results per query* videos. Leave empty when you only provide URLs.

## `startUrls` (type: `array`):

Video, Shorts, channel (`/@handle`, `/channel/UC…`, `/c/…`), channel tab (`/videos`, `/shorts`, `/streams`), playlist or search-results URLs. Channel URLs also produce one channel profile record. Bare `@handle` entries work too.

## `maxItems` (type: `integer`):

Hard cap on the number of videos saved in the whole run. Channel profile records are extra and not counted.

## `maxResultsPerQuery` (type: `integer`):

Videos to collect for each search query, channel, playlist or search URL (YouTube serves ~20 per page).

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

Only applies to search queries.

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

Only videos uploaded within this period (search queries only).

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

Filter by length (search queries only). Short = under 4 min, medium = 4–20 min, long = over 20 min.

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

Optional YouTube search features; a video must match all of them (search queries only).

## `includeShorts` (type: `boolean`):

Search: also return Shorts (the 'videos only' filter is dropped). Channels: also read the Shorts tab after the Videos tab. Shorts have no duration or publish date until you enable video details.

## `includeStreams` (type: `boolean`):

For channel URLs, also read the channel's Live / past streams tab after the Videos tab.

## `includeChannelInfo` (type: `boolean`):

For each channel URL, also save one channel record (name, handle, subscribers, video count, total views, description, country, join date, links). Billed as a `channel-result`.

## `includeVideoDetails` (type: `boolean`):

Open every video to add: full description, exact likes, exact views, category, tags/keywords, chapters, exact upload date, and duration for Shorts and streams. Billed as an extra `video-details` event per video and slower (about 2 requests per video).

## `language` (type: `string`):

Interface language sent to YouTube. Numbers are parsed best in English.

## `region` (type: `string`):

Country used to localise results.

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

Starts on Apify datacenter proxies and automatically falls back to RESIDENTIAL proxies for the rest of the run if YouTube blocks the requests.

## Actor input object example

```json
{
  "searchQueries": [
    "lofi hip hop"
  ],
  "startUrls": [],
  "maxItems": 50,
  "maxResultsPerQuery": 50,
  "sortBy": "relevance",
  "uploadDate": "any",
  "duration": "any",
  "features": [],
  "includeShorts": false,
  "includeStreams": false,
  "includeChannelInfo": true,
  "includeVideoDetails": false,
  "language": "en",
  "region": "US",
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

All videos and channel records collected during the run

# 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": [
        "lofi hip hop"
    ],
    "startUrls": [],
    "maxItems": 50,
    "maxResultsPerQuery": 50,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("fabrikit/youtube-videos-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": ["lofi hip hop"],
    "startUrls": [],
    "maxItems": 50,
    "maxResultsPerQuery": 50,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("fabrikit/youtube-videos-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": [
    "lofi hip hop"
  ],
  "startUrls": [],
  "maxItems": 50,
  "maxResultsPerQuery": 50,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call fabrikit/youtube-videos-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fabrikit/youtube-videos-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/ppn9xqgQ2jnjJzM0z/builds/hrpoVeukBVUy9ifoA/openapi.json
