YouTube Keyword and Tag Research Notebook (Autocomplete + Competitor Tags)
YouTube tag generator sites hand you a list of words with no reasons behind them. This free Google Colab notebook does the research a good tag list should come from: YouTube autocomplete for your seed terms, plus the titles, tags and view counts of the videos that already rank for them, pulled from the official YouTube Data API. You see where every keyword, title phrase and tag comes from, and which searches no top video targets yet.
Who it’s for
YouTube creators, video marketers and SEOs who plan videos around search, and anyone who wants to build a keyword universe for a channel from real data.
How to use it
- Open the notebook in Colab and run it with
USE_SAMPLE = True. It uses real autocomplete responses saved on 24 October 2026 and a sample set of API responses, so you see every table without a key. - Add your topics to
SEEDSand the ones you want competitor data for toCOMPETITOR_SEEDS, and set the language and country. - Create a free YouTube Data API v3 key in Google Cloud, save it in Colab Secrets as
YOUTUBE_API_KEY, and setUSE_SAMPLE = False. - Run the notebook and work through the topic groups, the tag and title tables and the gap list.
- Edit the suggested tag list by hand, then export the CSVs and the Excel workbook for Google Sheets.
What you get
- Autocomplete expansions (a to z, questions, modifiers) grouped into readable topics such as questions, tools, courses and year
- The top videos per seed with title, channel, tags, views, views per day, publish date and duration
- Tag frequency and co-occurrence, plus title n-grams and title patterns with median views
- Gaps: autocomplete phrases that no top video uses in its title or tags
- A suggested tag list with the reason for each tag, counted against YouTube’s 500-character limit the way YouTube counts it
Limits and costs
The API is free within the default quota: each seed costs one search.list call (100 a day in its own bucket) and one videos.list call (1 unit of 10,000 a day). The autocomplete endpoint is undocumented, so Google can change or block it; the notebook records failures and keeps going. Autocomplete shows predicted queries, not search volume. And keep tags in proportion: YouTube’s own help centre says the title, thumbnail and description matter more, and that tags play a minimal role unless your topic is often misspelled. I’d use this mainly for keyword and title research, with the tag list as the last small step.
Read YouTube SEO: how to boost video visibility and grow your channel for the full workflow and How to do a YouTube SEO audit to benchmark the channels you find here, and build it into a wider keyword strategy in the Semantic AI-powered SEO Keyword Research course.
What’s included
- YouTube autocomplete for any seed, expanded a to z plus questions and modifiers, grouped into topics
- Top-ranking videos' titles, tags, views and publish dates from the official YouTube Data API v3
- Tag frequency and co-occurrence, title n-grams and title patterns with median views
- Gap list of searches no top video targets, and a tag list that fits the 500-character limit
- Runs with no key in sample mode; costs 2 API calls per seed live, with CSV and Excel export
Where this resource is used on MLforSEO
Walkthroughs on the blog
Concepts behind it
More video and visual resources
- Coding Script or NotebookImage SEO Audit and Bulk AI Alt Text Generator (Colab Notebook)
- ChecklistYouTube SEO Checklist: Improve Video Visibility and Channel Health (Checklist)
- Coding Script or NotebookImage Clustering by Color with Three Machine Learning Approaches for Visual Content Organization
- Keyword research · No-Code TemplateTopical Map Template and Generator Based on the EAV Model (Google Sheets)
- Keyword research · No-Code TemplateKeyword Mapping Template with Intent and Cannibalisation Flags (Google Sheets)
- Keyword research · Coding Script or NotebookFree Keyword Clustering Tool (SERP-Overlap + Embeddings Hybrid)
See all 4 video and visual resources →See all 22 keyword research resources →See all 42 coding script or notebook resources →

