# Youtube Metadata Scraper (Transcripts Included 😋) (`toludare/youtube-metadata-scraper-all`)

Introducing the most comprehensive and robust YouTube Metadata Scraper on Apify, built for videos and shorts. Get detailed metadata, including title, description, video length, tags, like count, view count, comment count, and even full transcripts.

- **URL**: https://beta-securitybyobscurity.apify.com/toludare/youtube-metadata-scraper-all.md
- **Developed by:** [tolu.](https://beta-securitybyobscurity.apify.com/toludare) (community)
- **Categories:** Videos, SEO tools, Other
- **Stats:** 37 total users, 8 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

$5.00/month + usage

To use this Actor, you pay a monthly rental fee to the developer. The rent is subtracted from your prepaid usage every month after the free trial period.
You also pay for the Apify platform usage, which gets cheaper the higher Apify subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#rental-actors

# README

## Youtube Metadata Scraper (Transcripts Included 😋)

Introducing the most **comprehensive** and **robust** Youtube Metadata web scraper on Apify. Get video details, channel details, engagement statistics, transcripts and more from Youtube videos and shorts via a single interface.

### 😋 Features 😋

- Extract complete video metadata including video title, description, thumbnail, channel details, engagement stats and full transcripts.
- Seamlessly handle both videos and shorts URL through a single interface.
- Easily customize transcript options in the input settings including transcript formats and languages.
- Access detailed timestamps, including start times and time ranges for each transcript segment.

### 👩‍🍳 Input Parameters 👩‍🍳

|Parameter|Type|Description|Default Value|
|:---------|:----|:-----------|:-------------:|
|startURLs|array|At least one Youtube URL (Video and Shorts URL are supported). The maximum number of URLs is 1000.|-|
|extractTranscript|boolean|If selected, includes transcript in the result|true|
|transcriptFormat|`raw`|`timestamp`|If `raw`, return transcript as a string without timestamp information. If `timestamp`, include timestamp information for each transcript segment|`timestamp`|
|includeEnglishAG|boolean|If selected, includes English (auto-generated) option in transcript|false|
|includeNonEnglish|boolean|If selected, includes non-English languages in transcripts|false|
|proxy|object|Apify's proxy configuration. Choose RESIDENTIAL proxies for reliable runs|RESIDENTIAL|

### 🍖 Output Example 🍖

`includeEnglishAG` and `includeNonEnglish` was set to `False` while `transcriptFormat` was set to `raw`:

```json
{
  "id": "4KbrxIpQgkM",
  "url": "https://www.youtube.com/watch?v=4KbrxIpQgkM",
  "title": "Nothing Phone 3 Review: They Lied!",
  "description": "So you want to be a flagship?\n\nNothing Phone 3: https://geni.us/Lv2Fcd\n\nMKBHD Merch: http://shop.MKBHD.com\n\nPlaylist of MKBHD Intro music: https://goo.gl/B3AWV5\n\nPhone provided by Nothing for review.\n\n~\nhttp://twitter.com/MKBHD\nhttp://instagram.com/MKBHD\nhttp://facebook.com/MKBHD",
  "lengthInSeconds": 938,
  "uploadDatetime": "2025-07-08T13:00:59+00:00",
  "category": "Science & Technology",
  "tags": [
    "Nothing Phone",
    "Nothing Phone 3",
    "Nothing Phone 3 review",
    "MKBHD",
    "Nothing phone MKBHD",
    "Nothing Phone 3 review MKBHD",
    "Nothing 3",
    "Nothing 3 vs",
    "Nothing phone 3 vs",
    "flagship",
    "true flagship",
    "glyph",
    "glyph matrix"
  ],
  "thumbnail": "https://i.ytimg.com/vi/4KbrxIpQgkM/hqdefault.jpg",
  "channelID": "UCBJycsmduvYEL83R_U4JriQ",
  "channelURL": "http://www.youtube.com/@mkbhd",
  "channelUsername": "mkbhd",
  "channelDisplayName": "Marques Brownlee",
  "channelSubscribers": "20.1M",
  "viewCount": 2493676,
  "likeCount": 81093,
  "commentCount": 6785,
  "transcripts": [
    {
      "language": "English",
      "content": "(funky upbeat music) - This is the Nothing Phone 3 and yeah, it's ugly. (funky music) You know, people say beauty is in the eye of the beholder and stuff like that. I get it. You can find\nbeauty in anything, for sure. But also, you know,\nthere's a nice alignment to things that feels good. And you know, when things are, when things are where\nyou expect them to be, doesn't that feel better? Okay. All right, carcinisation. I learned about this recently..."
    }
  ]
}
```

Also, here is an excerpt of the transcript when `transcriptFormat` is set to `timestamp`:

```json
{
  ...,
  "transcripts": [
    {
      "language": "English",
      "content": [
        {
          "startMs": 291,
          "endMs": 3374,
          "startTime": "0:00",
          "text": "(funky upbeat music)"
        },
        {
          "startMs": 18600,
          "endMs": 21390,
          "startTime": "0:18",
          "text": "- This is the Nothing Phone 3"
        },
        {
          "startMs": 21390,
          "endMs": 23974,
          "startTime": "0:21",
          "text": "and yeah, it's ugly."
        },
        ...,
      ]
    }
  ]
}
```

### 🚫 Limitations 🚫

- The actor will most likely fail if `RESIDENTIAL` proxies are not used.

***

This scraper is under active development and suggestions or feature requests will be greatly appreciated. If you have suggestions, feature requests, or encounter any issues, feel free to:

- Open an issue - https://console.apify.com/actors/f2jWZcFtNz7SeL7We/issues
- Email me directly at isaactoluwani30@gmail.com

# Actor input Schema

## `startURLs` (type: `array`):

One or more Youtube videos or shorts URLs. The maximum number of URLs is 1000.

## `extractTranscript` (type: `boolean`):

Click to also include the transcript of videos in the results.

## `transcriptFormat` (type: `string`):

Select the format of the transcript. This option is only valid if `extractTranscript` is `true`.

## `includeEnglishAG` (type: `boolean`):

Only valid if `extractTranscript` is `true`.

## `includeNonEnglish` (type: `boolean`):

Only valid if `extractTranscript` is `true`.

## `proxy` (type: `object`):

Select proxies to be used by your crawler. Choose `RESIDENTIAL` proxies or input your own. Any other option is unreliable and will most likely lead to failed runs.

## Actor input object example

```json
{
  "startURLs": [
    "https://www.youtube.com/watch?v=RjHzznQy6hI",
    "https://www.youtube.com/shorts/uznhAxHKVTI"
  ],
  "extractTranscript": true,
  "transcriptFormat": "timestamp",
  "includeEnglishAG": false,
  "includeNonEnglish": false,
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# 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 = {
    "startURLs": [
        "https://www.youtube.com/watch?v=RjHzznQy6hI",
        "https://www.youtube.com/shorts/uznhAxHKVTI"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("toludare/youtube-metadata-scraper-all").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 = { "startURLs": [
        "https://www.youtube.com/watch?v=RjHzznQy6hI",
        "https://www.youtube.com/shorts/uznhAxHKVTI",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("toludare/youtube-metadata-scraper-all").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 '{
  "startURLs": [
    "https://www.youtube.com/watch?v=RjHzznQy6hI",
    "https://www.youtube.com/shorts/uznhAxHKVTI"
  ]
}' |
apify call toludare/youtube-metadata-scraper-all --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=toludare/youtube-metadata-scraper-all",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Youtube Metadata Scraper (Transcripts Included 😋)",
        "description": "Introducing the most comprehensive and robust YouTube Metadata Scraper on Apify, built for videos and shorts. Get detailed metadata, including title, description, video length, tags, like count, view count, comment count, and even full transcripts.",
        "version": "1.1",
        "x-build-id": "pu88bicrgze0er86J"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/toludare~youtube-metadata-scraper-all/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-toludare-youtube-metadata-scraper-all",
                "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/toludare~youtube-metadata-scraper-all/runs": {
            "post": {
                "operationId": "runs-sync-toludare-youtube-metadata-scraper-all",
                "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/toludare~youtube-metadata-scraper-all/run-sync": {
            "post": {
                "operationId": "run-sync-toludare-youtube-metadata-scraper-all",
                "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",
                "required": [
                    "startURLs"
                ],
                "properties": {
                    "startURLs": {
                        "title": "Start URLs",
                        "maxItems": 1000,
                        "uniqueItems": true,
                        "type": "array",
                        "description": "One or more Youtube videos or shorts URLs. The maximum number of URLs is 1000.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "extractTranscript": {
                        "title": "Extract Transcript",
                        "type": "boolean",
                        "description": "Click to also include the transcript of videos in the results.",
                        "default": true
                    },
                    "transcriptFormat": {
                        "title": "Transcript Format",
                        "enum": [
                            "timestamp",
                            "raw"
                        ],
                        "type": "string",
                        "description": "Select the format of the transcript. This option is only valid if `extractTranscript` is `true`.",
                        "default": "timestamp"
                    },
                    "includeEnglishAG": {
                        "title": "Include English (auto-generated) language in transcript",
                        "type": "boolean",
                        "description": "Only valid if `extractTranscript` is `true`.",
                        "default": false
                    },
                    "includeNonEnglish": {
                        "title": "Include Non-English languages in transcript",
                        "type": "boolean",
                        "description": "Only valid if `extractTranscript` is `true`.",
                        "default": false
                    },
                    "proxy": {
                        "title": "Proxy Configuration",
                        "type": "object",
                        "description": "Select proxies to be used by your crawler. Choose `RESIDENTIAL` proxies or input your own. Any other option is unreliable and will most likely lead to failed runs.",
                        "default": {
                            "useApifyProxy": true,
                            "apifyProxyGroups": [
                                "RESIDENTIAL"
                            ]
                        }
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
