# YouTube Trend Keyword Finder (`myagizm/youtube-trend-keyword-finder`) Actor

Discover related YouTube keywords with 0–100 popularity scores, recent-content signals, views and supporting videos. Localized suggestions and CSV-ready rankings.

- **URL**: https://apify.com/myagizm/youtube-trend-keyword-finder.md
- **Developed by:** [MYM](https://apify.com/myagizm) (community)
- **Categories:** SEO tools, Videos, Social media
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.15 / 1,000 ranked keywords

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 Trend Keyword Finder 🎯

Discover related YouTube keywords from one topic or a short seed list. Get ranked keyword ideas, supporting videos, view totals, recent-content shares and direct example links in a CSV-ready table.

### What you get

- Localized YouTube autocomplete suggestions.
- Relevant phrases and hashtags appearing in sampled video titles and public description snippets.
- A transparent 0–100 popularity/recency score, not invented monthly search volume.
- Images, example URLs, sample counts and explicit nulls for unavailable metrics.

### Input example

```json
{"seedKeywords":["sourdough","ekşi maya","mechanical keyboard"],"maxKeywords":50,"sampleSize":30,"country":"US","language":"en","includeExamples":true}
```

Use 1–5 seeds, maxKeywords 1–100 per seed (default 50), sampleSize 4–40 (default 30). Country influences search and suggestions. Language influences suggestions; publication-label parsing uses English. includeExamples controls the nested example list, not the flat example URL.

### How the score works

Candidates come from suggestions, 2–4-word phrases in titles/description snippets, and visible hashtags. Phrases must include a seed token, or the complete phrase must appear in at least two sampled titles. Repeated generic words alone do not make a phrase relevant. Case, accents, punctuation and hashtag prefixes are normalized. Each sampled video is counted once per keyword.

V = log(1 + summed matching-video views) / log(1 + maximum sampled-video views × sampleCount), capped at 1.
F = matching-video count / sampleCount.
R = 0.7 × share published within 7 days + 0.3 × share within 30 days, among matching videos with dates.
P = 1 − (suggestionPosition − 1) / suggestionCount; 0 if not a suggestion.
E = min(1, engagementRate / 10), where engagementRate is 100 × (likes + comments) / views if all components are available.
Score = 100 × (40V + 25F + 20R + 10P + 5E) / available weight. R and E weights are omitted when unavailable; the base weight is 75. Scores are rounded to two decimals. Ties use frequency then keyword.

Half the video budget is drawn from relevance results and half from videos filtered to the recent month. This intentionally balances established interest with new content; the score is relative to this sample, not a global trend index. Publication timestamps are estimates reconstructed from relative labels (weeks = 7 days, months = 30, years = 365); examples include publishedAtApproximate and the original label. Borderline 7/30-day shares are approximate.

### Output fields

| Field | Meaning |
|---|---|
| seedKeyword, keyword, rank, score | Seed, normalized keyword and per-seed ranking |
| relation, sources | Discovery method(s): autocomplete, title_ngram, description_ngram, caption_ngram, video_tag or hashtag |
| frequency, sampleCount | Matching unique videos and all sampled unique videos |
| totalViews, avgViews | Sum/mean of known views across matching sampled videos |
| avgLikes, avgComments, engagementRate | Nullable: public search does not normally expose these |
| recencyScore | 0–100 weighted recent-content share |
| recent7DayShare, recent30DayShare, matchedDateCount | Raw shares and date coverage |
| growthSignal, growthSignalReason | Null: one snapshot does not prove growth |
| suggestionPosition | Autocomplete position, or null |
| topExamples, topExampleUrl, thumbnailUrl | Up to three supporting videos and flat URL/image |
| platform, scrapedAt, scoreVersion, dataCoverage, id | Platform, observation time, formula version, coverage and stable seed/keyword ID |

### Limits and honest coverage

sampleSize is a maximum, not a guarantee. Duplicate videos across the two lists are counted once. Autocomplete-only keywords may have frequency 0 and no examples. No search volume or growth history is fabricated. Up to six sampled videos per seed are enriched with available video tags, full descriptions and publication dates. Public caption tracks are attempted when exposed and their first 60 words can contribute candidates. Captions may be unavailable. Channel tags are not fetched. Likes and comment counts are included only when an exact public count is exposed on the sampled watch page. Missing counts are null, never synthetic zeros.

### Pricing and free plan

Pay per delivered keyword; no start fee. Free Apify plans have a shared 40-result allowance per Actor per user per UTC day, counted by requested results; all free-plan users also share the daily YouTube service budget. Paid Apify plans are not rate-limited. Input errors finish SUCCEEDED with no results and no charge; see OUTPUT for the reason. Genuine retrieval failures finish FAILED without delivery or keyword charges.

### 中文说明 🇨🇳

输入一个或多个 YouTube 主题，获得相近关键词、0–100 分排名、样本视频播放量、近期内容比例以及视频链接和图片。

关键词来自自动补全、公开视频标题和搜索结果中的描述片段、可见话题标签。默认每个主题最多 50 个词；视频样本默认 30 个，允许 4–40 个；最多 5 个主题。country 影响搜索与建议，language 影响建议。includeExamples 决定是否输出嵌套示例列表。

评分权重：播放量对数指标 40、出现频率 25、近期比例 20、建议位置 10、可用互动率 5。近期指标为 7 天比例×0.7 + 30 天比例×0.3。缺失近期或互动指标时移除该权重，并按可用权重归一化到 100。此分数仅针对当前样本，不是全站搜索量或真实增长率。

一半样本来自相关结果，一半来自最近一个月筛选结果。发布日期根据相对时间估算，示例标有 publishedAtApproximate。缺失的点赞、评论、互动率用 null 表示；单次采样不能证明增长，因此 growthSignal 为 null。每个主题最多补充六个视频的可用标签、完整描述和发布日期，并尝试公开字幕。不抓取频道标签；公开视频页显示准确点赞或评论数时才使用。字幕可能不可用。

按实际交付关键词计费，不收启动费。免费计划每个用户每天每个 Actor 共用 40 条请求额度，UTC 零点重置；所有免费用户同时共用每日 YouTube 服务预算。付费计划不受这些限制。输入错误以 SUCCEEDED 结束，无结果、无收费；原因请查看 OUTPUT。真正采集故障以 FAILED 结束，不交付、不收关键词费用。

#### Shared YouTube free-plan daily budget

All free-plan YouTube users share one $1 daily service budget across all YouTube Actors (not $1 per user or Actor), resetting at 00:00 UTC. When exhausted, the run finishes SUCCEEDED with 0 rows and no charge; OUTPUT contains ok:false and errorType:FREE_LIMIT. Any paid Apify plan is unlimited.

#### YouTube 免费计划共享每日预算

所有 YouTube 免费计划用户、所有 YouTube Actor 共用一个每日 $1 的服务预算（不是每位用户或每个 Actor 各 $1），于 UTC 00:00 重置。预算耗尽时运行以 SUCCEEDED 结束，0 条结果、无收费；OUTPUT 返回 ok:false 和 errorType:FREE_LIMIT。任何付费 Apify 计划均不受此限制。

# Actor input Schema

## `seedKeywords` (type: `array`):

1–5 YouTube topics, up to 120 characters each. Empty input finishes without results or charge.

## `maxKeywords` (type: `integer`):

Maximum ranked keywords per seed. Free plans share a 40-result daily allowance for this Actor.

## `sampleSize` (type: `integer`):

Sample up to this many unique videos across relevance and recent-month results; fewer may be available.

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

Two-letter uppercase country code, e.g. US or TR. Influences search and suggestions.

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

Language code, e.g. en, tr or zh-CN. Localizes suggestions; video labels are parsed in English.

## `includeExamples` (type: `boolean`):

Include up to 3 supporting videos per keyword. The flat example URL remains available.

## Actor input object example

```json
{
  "seedKeywords": [
    "sourdough"
  ],
  "maxKeywords": 50,
  "sampleSize": 30,
  "country": "US",
  "language": "en",
  "includeExamples": true
}
```

# Actor output Schema

## `keywords` (type: `string`):

No description

## `json` (type: `string`):

No description

# 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 = {
    "seedKeywords": [
        "sourdough"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("myagizm/youtube-trend-keyword-finder").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 = { "seedKeywords": ["sourdough"] }

# Run the Actor and wait for it to finish
run = client.actor("myagizm/youtube-trend-keyword-finder").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 '{
  "seedKeywords": [
    "sourdough"
  ]
}' |
apify call myagizm/youtube-trend-keyword-finder --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,myagizm/youtube-trend-keyword-finder"
        }
    }
}
```

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/AqWD80vNYNU08J7yL/builds/xnAsHxyEplO6I6fah/openapi.json
