# YouTube Shorts Scraper (Official API) — By Keyword & Channel (`actor-forge/youtube-shorts-api`) Actor

Bring your own free YouTube API key. Get YouTube Shorts from any channel (YouTube's own Shorts list, not a guess) or by keyword, with views, likes, comments, duration, tags and publish date, via the official YouTube Data API v3. No scraping, no blocks. $1.20 per 1,000 Shorts.

- **URL**: https://apify.com/actor-forge/youtube-shorts-api.md
- **Developed by:** [ActorForge](https://apify.com/actor-forge) (community)
- **Categories:** Videos, Social media
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.20 / 1,000 short 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 Shorts Scraper (Official API) — By Keyword & Channel

Bring your own free YouTube API key. Get YouTube Shorts from any channel (YouTube's own Shorts list, not a guess) or by keyword, with views, likes, comments, duration, tags and publish date, via the official YouTube Data API v3. No scraping, no blocks. $1.20 per 1,000 Shorts.

**Bring your own free YouTube API key** and get **YouTube Shorts** from the **official YouTube Data API v3**, with no scraping, no proxies and no blocks. Two ways in, in one run:

- **Shorts by channel**: paste channel URLs, @handles or channel IDs. Each channel's Shorts come from **YouTube's own Shorts playlist** for that channel, so the list is exact (Shorts only, no long videos, no guessing from the Shorts tab), newest first. If a channel has no Shorts playlist, its uploads are checked by duration instead, and every row says which method was used (`shortSource`).
- **Shorts by keyword**: search terms run through YouTube search with the *short* length filter, then each result is checked: only videos of **3 minutes or less** that are not live are kept (YouTube allows Shorts up to 3 minutes since October 2024). Optional region, language, date range and sort order.

Every Short comes back as one row with **views, likes, comment count**, duration in seconds, title, description, tags, publish date, channel name, handle and ID, thumbnails, made-for-kids flag and the `youtube.com/shorts/…` link. Use it for Shorts analytics, trend and hashtag research, competitor tracking and creator discovery, or feed Sheets, Make, n8n or Zapier.

**$1.20 per 1,000 Shorts**, under a third of the leading Shorts scraper ($4.00 per 1,000), and no start fee beyond Apify's platform minimum. A channel's 10 newest Shorts cost about 3 of your 10,000 free daily quota units.

#### Get your free API key (about 60 seconds, no billing account)

1. Open the [Google Cloud Console](https://console.cloud.google.com/) and sign in with any Google account. Create a project (top bar → **New project**).
2. Go to **APIs & Services → Library**, search for **YouTube Data API v3** and click **Enable**.
3. Go to **APIs & Services → Credentials → Create credentials → API key** and copy the key (it starts with `AIza`).
4. Paste it into the **YouTube API key** field of this actor and run. The field is a secret input: Apify stores it encrypted, and the actor never logs it or writes it to the output.

You do not need to add a billing account. Each Google Cloud project gets **10,000 free quota units per day**, which reset at midnight Pacific Time. If you restrict the key, allow **YouTube Data API v3** and leave out HTTP-referrer or IP restrictions, because Apify runs on changing server IPs.

#### How far your free quota goes

| Input | API calls | Quota units | Shorts per day on 10,000 units |
| --- | --- | --- | --- |
| channel | `channels.list` + `playlistItems.list` (Shorts playlist, 50 per call) + `videos.list` (stats) | 1 per channel + about 2 per 50 Shorts | about 250,000 Shorts |
| keyword | `search.list` (50 per page) + `videos.list` | **101 per page of 50 results** | about 100 pages (up to 5,000 results) |

Keyword search is the expensive call: YouTube charges 100 units per page. The run log shows an estimate before any call is made. If your key runs out (a `403 quotaExceeded` error), the actor **stops cleanly** with a clear message, keeps the Shorts already delivered, and does not charge for the failed call.

#### Official API only, and your data stays yours

- All data comes from the official **YouTube Data API v3** (`https://www.googleapis.com/youtube/v3/`) using **your own key and quota**. Nothing is scraped from youtube.com, and there are no proxies, cookies or logins.
- We never hold, share or pool API keys, and no default key is built in. ActorForge sells the API client; the data is fetched under your key.
- ActorForge keeps no copy of API data after the run. Rows go only to your run's dataset, which belongs to you. YouTube's Developer Policies require stored API data to be **refreshed or deleted at least every 30 days**, so set a retention period on your datasets or re-run to refresh them. Statistics such as view counts change constantly anyway.
- By using this actor you also agree to the [YouTube Terms of Service](https://www.youtube.com/t/terms). Google's handling of API requests is covered by the [Google Privacy Policy](https://policies.google.com/privacy). You can review or revoke your key at any time in the Google Cloud Console, and revoke API access for your Google account at [Google security settings](https://myaccount.google.com/permissions).

*This actor uses YouTube API Services. It is not affiliated with or endorsed by YouTube or Google.*

### What data does it return?

Every run outputs clean, schema-validated rows like these:

| title | channelTitle | channelHandle | publishedAt | durationSec | viewCount | likeCount | commentCount | shortSource | url |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Last To Fall Wins | MrBeast | @mrbeast | 2026-10-16T16:00:02Z | 24 | 98359162 | 915977 | 11485 | uush-playlist | https://www.youtube.com/shorts/Y8IJi7iP5vk |
| Giving $10,000 To A Random Subscriber | MrBeast | @mrbeast | 2026-10-09T16:00:01Z | 40 | 45216651 | 1152310 | 26486 | uush-playlist | https://www.youtube.com/shorts/aNI2jv7lBPQ |
| What’s Inside My Briefcase? | MrBeast | @mrbeast | 2026-09-27T16:00:14Z | 40 | 94781973 | 1331567 | 24600 | uush-playlist | https://www.youtube.com/shorts/CEJXqm2eiJ0 |

### How much does it cost?

Transparent pay-per-event pricing — you only pay for what you get, and the
actor **always respects your run budget**: set a maximum total charge and it
stops cleanly at the cap instead of overrunning.

| Event | Price | Charged | Worked example |
| --- | --- | --- | --- |
| `short-result` | $0.0012 | per Short row delivered (full details and stats) | 1,000 Shorts = $1.20 (streamers/youtube-shorts-scraper: $4.00 per 1,000) |
| `search-page` | $0.002 | per keyword search page of up to 50 results that returned Shorts (it costs 100 of your quota units) | One keyword, 40 Shorts kept = $0.002 + 40 × $0.0012 = $0.05 |
| `apify-actor-start` | $0.00005 | per run per GB of memory (platform start fee) | One run at 256 MB = $0.0000125 |

### Input options

| Field | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `apiKey` | string | no | — | Required. Your own free YouTube Data API v3 key (starts with AIza). Get one in about a minute: console.cloud.google.com → create a project → APIs & Services → Library → enable "YouTube Data API v3" → Credentials → Create credentials → API key. No billing account is needed, and the free quota is 10,000 units per day. The key is stored encrypted by Apify, used only for this run's calls to googleapis.com, and never logged or written to the output. |
| `mode` | string | no | `"shorts"` | Always shorts on this listing (Shorts from channels and keywords). |
| `channels` | array | no | `[]` | Channel URLs (youtube.com/@handle, /@handle/shorts, /channel/UC…, /user/name), @handles or channel IDs (UC…). Each channel's Shorts come from YouTube's own Shorts playlist, so the list is exact, newest first (about 2 quota units per 50 Shorts plus 1 per channel). If a channel has no Shorts playlist, its uploads are checked by duration instead. |
| `maxVideosPerChannel` | integer | no | `100` | Newest Shorts per channel. Every 50 Shorts cost about 2 of your quota units. |
| `publishedAfter` | string | no | `""` | Optional date (YYYY-MM-DD): only Shorts published on or after it. For channels, paging stops at older Shorts, saving quota; for keywords, YouTube filters the search. |
| `searchQueries` | array | no | `[]` | Optional search terms. Each is searched with YouTube's "short" length filter (under 4 minutes), and only videos of 3 minutes or less that are not live are kept. Each page of up to 50 results costs 100 of your 10,000 daily quota units. |
| `maxResultsPerQuery` | integer | no | `50` | Search results read per keyword (YouTube returns at most about 500). Each 50 = one search page (100 quota units). Results longer than 3 minutes are dropped and not charged, so you can get fewer Shorts than this. |
| `order` | string | no | `"relevance"` | Sort order for keyword search. |
| `publishedBefore` | string | no | `""` | Optional date (YYYY-MM-DD) for keyword search. |
| `regionCode` | string | no | `""` | Optional 2-letter country code (US, GB, DE …): keyword results available in that country. |
| `relevanceLanguage` | string | no | `""` | Optional ISO 639-1 language code (en, es, de …): keyword results most relevant to that language. |

### Limits & honest notes

- **You need your own free YouTube Data API v3 key** (see the 4-step guide above). Without one the run finishes at once with a single free row of instructions, and nothing is charged.
- Quota is per Google Cloud project: 10,000 units/day for free. channels.list, playlistItems.list and videos.list cost 1 unit each, and search.list costs 100. A `quotaExceeded` error stops the run cleanly; Shorts already delivered are kept, and the failed call is free.
- Channel Shorts come from YouTube's per-channel Shorts playlist (`UUSH…`). It is a system playlist YouTube does not document, so it could change; if it is missing for a channel, the actor falls back to checking uploads by duration (3 minutes or less, not live) and marks those rows `shortSource: duration-heuristic`. The fallback scans at most 250 uploads (or 5 × Max Shorts per channel) so a long-form channel cannot eat your quota.
- Keyword results use the duration check, because the API has no Shorts flag in search: a regular video of 3 minutes or less can appear. Results longer than 3 minutes are dropped and never charged, so a keyword can return fewer Shorts than Max search results.
- Only public data the API returns for an API key: no dislike counts (removed by YouTube), no revenue, no watch time, no audio/sound name and no Shorts remix data. Like counts hidden by the creator come back as null.
- Search returns at most about 500 results per keyword (a YouTube limit), and results can differ from what the YouTube app shows.
- You must refresh or delete stored API data within 30 days (YouTube Developer Policies III.E.4). We keep nothing after the run.
- The run's spend limit is respected: each page of Shorts is charged before it is delivered, and the run stops cleanly at the cap. Free rows (type error) cover invalid inputs and channels that are not found.

### Related ActorForge actors

- [YouTube Scraper (Official API) — Videos, Search & Stats](https://apify.com/actor-forge/youtube-api-scraper) — any video by URL, full search, channels and comments
- [YouTube Channel Scraper (Official API) — All Videos & Stats](https://apify.com/actor-forge/youtube-channel-api) — channel stats plus every upload, long videos included
- [YouTube Comments Scraper (Official API) — No Usernames](https://apify.com/actor-forge/youtube-comments-api) — comments on any Short or video, commenter identities stripped

### Changelog

- **2026-10-22** — Initial release: YouTube Shorts by channel from YouTube's own Shorts playlist (duration fallback), Shorts by keyword with the short-length filter and a 3-minute check, full stats via the official YouTube Data API v3 with your own key, clean quota-exceeded stop, pay-per-event billing.

***

*Built and maintained by **ActorForge**. Reliability first: every actor in the
portfolio is monitored by an automated nightly self-test, and breakages are
typically fixed the same day.*

# Actor input Schema

## `apiKey` (type: `string`):

Required. Your own free YouTube Data API v3 key (starts with AIza). Get one in about a minute: console.cloud.google.com → create a project → APIs & Services → Library → enable "YouTube Data API v3" → Credentials → Create credentials → API key. No billing account is needed, and the free quota is 10,000 units per day. The key is stored encrypted by Apify, used only for this run's calls to googleapis.com, and never logged or written to the output.

## `mode` (type: `string`):

Always shorts on this listing (Shorts from channels and keywords).

## `channels` (type: `array`):

Channel URLs (youtube.com/@handle, /@handle/shorts, /channel/UC…, /user/name), @handles or channel IDs (UC…). Each channel's Shorts come from YouTube's own Shorts playlist, so the list is exact, newest first (about 2 quota units per 50 Shorts plus 1 per channel). If a channel has no Shorts playlist, its uploads are checked by duration instead.

## `maxVideosPerChannel` (type: `integer`):

Newest Shorts per channel. Every 50 Shorts cost about 2 of your quota units.

## `publishedAfter` (type: `string`):

Optional date (YYYY-MM-DD): only Shorts published on or after it. For channels, paging stops at older Shorts, saving quota; for keywords, YouTube filters the search.

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

Optional search terms. Each is searched with YouTube's "short" length filter (under 4 minutes), and only videos of 3 minutes or less that are not live are kept. Each page of up to 50 results costs 100 of your 10,000 daily quota units.

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

Search results read per keyword (YouTube returns at most about 500). Each 50 = one search page (100 quota units). Results longer than 3 minutes are dropped and not charged, so you can get fewer Shorts than this.

## `order` (type: `string`):

Sort order for keyword search.

## `publishedBefore` (type: `string`):

Optional date (YYYY-MM-DD) for keyword search.

## `regionCode` (type: `string`):

Optional 2-letter country code (US, GB, DE …): keyword results available in that country.

## `relevanceLanguage` (type: `string`):

Optional ISO 639-1 language code (en, es, de …): keyword results most relevant to that language.

## Actor input object example

```json
{
  "mode": "shorts",
  "channels": [
    "https://www.youtube.com/@MrBeast"
  ],
  "maxVideosPerChannel": 10,
  "publishedAfter": "",
  "searchQueries": [],
  "maxResultsPerQuery": 50,
  "order": "relevance",
  "publishedBefore": "",
  "regionCode": "",
  "relevanceLanguage": ""
}
```

# Actor output Schema

## `shorts` (type: `string`):

Short rows (type short, charged): title, channel, handle, published date, duration, views, likes, comments, tags, thumbnails, /shorts/ URL and shortSource.

## `errors` (type: `string`):

Free rows (type error) for invalid, not-found or private inputs and videos with comments disabled.

# 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 = {
    "channels": [
        "https://www.youtube.com/@MrBeast"
    ],
    "maxVideosPerChannel": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("actor-forge/youtube-shorts-api").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 = {
    "channels": ["https://www.youtube.com/@MrBeast"],
    "maxVideosPerChannel": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("actor-forge/youtube-shorts-api").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 '{
  "channels": [
    "https://www.youtube.com/@MrBeast"
  ],
  "maxVideosPerChannel": 10
}' |
apify call actor-forge/youtube-shorts-api --silent --output-dataset

```

## MCP server setup

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

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/URgEDRHuAGGVIpRDG/builds/zji0vvuUYX09P35ed/openapi.json
