YouTube Channel Filter

Filter YouTube videos by channel, keyword, duration, language, live streams and members-only content. Full blocklist/whitelist management with quick action buttons on video cards.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

Autor
MayoHu
Dziennych instalacji
1
Wszystkich instalacji
52
Oceny
1 1 0
Wersja
1.1.1-rc1
Utworzono
29-08-2025
Zaktualizowano
27-04-2026
Rozmiar
195 KB
Licencja
MIT
Dotyczy

YouTube Channel Filter — User Manual

v1.1.0 | Tampermonkey userscript | Traditional Chinese & English


🔗 Table of Contents


Installation

  1. Install Tampermonkey browser extension (Chrome / Firefox / Edge all work)
  2. Open the userscript file: youtube-channel-filter-v1.1.0.user.js
  3. Tampermonkey will prompt for installation → confirm
  4. Open any YouTube page — you should see the 🔍 floating button in the bottom-right corner

Verify version

Open the panel (click 🔍 or use Tampermonkey menu "⚙️ Open management panel"). The top-right corner of the panel should show v1.1.0.


Language Switch

The UI follows system language by default (Traditional Chinese / English). To switch:

  1. Click 🔍 to open the management panel
  2. Go to the "⚙️ Settings" tab
  3. At the very top, in the "⚙️ Global settings" section → find the "🌐 Interface language" dropdown
  4. Select "繁體中文" or "English" → effective immediately (panel and all card buttons update)

The language setting is stored in ytf_lang and syncs across browser tabs.


🚫 Blocklist

All channels added to this list will have their videos completely hidden from all listing pages (home, search, recommendations, subscriptions, etc.).

Adding a channel

Method A: Quick-add from video card

  1. Hover any video card
  2. A "🚫 Block channel" button slides out at the bottom → click it
  3. All videos from that channel disappear instantly

Method B: Manual add from panel

  1. Open panel → "🚫 Blocklist" tab
  2. Click "+ Add"
  3. Enter channel name or @handle; optionally check "⌥R.* Regex mode"
  4. Click "Confirm"

Managing entries

Button Description
✏️ Edit channel name / ID / Regex mode / tags
Remove (two-step confirmation to prevent accidents)
🏷 Open the tag management panel for this entry
🗑 Clear all Clear the entire blocklist (with confirmation)

Search

The search bar at the top filters by channel name or @handle; the tag filter bar filters by tag.


⭐ Whitelist

All channels added to this list will always be shown (bypassing all filter rules).

Use cases

  • Protect important channels from being accidentally blocked by keyword or other filters
  • Combined with "⭐ Show only whitelisted channels" setting, create a trusted-channel-only browsing mode (e.g., for children)
  • Whitelisted channels will NOT show the "🚫 Block" quick-action button (reduces accidental blocks)

Adding / managing

Operations are the same as the Blocklist (use the card's ⭐ quick button or add manually from the panel).

Whitelist entries also support:

  • Tag management (🏷 button)
  • Edit (✏️ button)
  • Tag filter bar (top chip row)
  • CSV export with tags column

Whitelist and Blocklist have completely independent tag pools — identical tag names are counted separately.


🔤 Keywords

Create multiple "keyword groups", each containing multiple keywords. A video whose title or description matches any keyword is hidden.

Creating a group

  1. Click "+ New group"
  2. Enter group name (e.g., "Politics", "Sponsored", "Harmful")
  3. Choose scope: Title / Description (at least one required)
  4. Click "Create"

Adding keywords

  1. Within the group, click "+ Keyword"
  2. Enter keyword or Regex pattern
  3. Check the "Regex" checkbox to enable regex mode
  4. Click "Add"

Managing groups

Button Description
🔴 / ⚪ Enable / disable the group (preserves data)
↑ ↓ Adjust group priority
✏️ Edit group name / scope
🗑 Delete group Delete the entire group (with confirmation)

Searching groups / keywords

The search bar above the group list filters in real time:

  • Type "sponsored" → only groups whose name or any keyword contains "sponsored" appear
  • Matching keyword chips are highlighted in gold; matching group names show in gold text

⚙️ Settings (filters)

The Settings page is organized into sections, from top to bottom:

💾 Save settings (pinned at top)

Click this to save all configuration changes.

⚙️ Global settings

  • 🌐 Interface language: 繁體中文 / English
  • Show toasts: if disabled, toasts stop appearing but logs still record
  • Show Stats & History tabs: if disabled, these tabs are hidden but data is still tracked

⭐ Whitelist-only mode

When enabled, only whitelisted channels are shown; everything else is hidden. This is the core switch for the child-safety setup.

⏱ Video duration

  • Min / max duration (seconds)
  • Example: 60 / 600 → only show videos between 1 and 10 minutes

📡 Live / Premiere

  • Hide live streams
  • Hide upcoming premieres

👑 Members-only

Hide members-only videos.

📅 Upload date

  • Supports semantic ranges: "within N days/weeks/months/years"
  • Default: "within 30 days"

👁 View count

  • Min / max views
  • Accepts plain numbers (10000) or abbreviations (10K = 10,000, 1M = 1,000,000)
  • Live-stream viewer counts are not counted

🌐 Language filter

  • Mode: block specific languages / allow only specific languages
  • Common language checkboxes: Japanese / Korean / Chinese / English / Russian / Arabic / Spanish / French / German / Portuguese / Hindi / Thai / Vietnamese / Indonesian / Turkish / Italian
  • Custom codes: comma-separated BCP-47 codes (e.g., nl, pl, sv)
  • Detection method: Title character-set analysis. Latin-based languages (Vietnamese, French, etc.) have lower detection accuracy due to character overlap — combine with keyword filters for better results

📊 Stats & 📋 History

📊 Stats

  • Keyword ranking: which keywords trigger hides most often
  • Channel ranking: which channels get hidden most often (shows names for easy identification)
  • Two-column side-by-side layout for clarity

📋 History

  • Last 500 entries of hidden videos
  • Includes: video title, channel name, channel ID, trigger reason, hidden time
  • Supports search and CSV export

💾 Import / Export

Export all settings (JSON)

Bundles all blocklist, whitelist, keywords, and filter settings into a single JSON file.

Individual exports (CSV)

  • Blocklist CSV (with Tags column)
  • Whitelist CSV (with Tags column)
  • Keywords CSV (with group name, scope, Regex flag)
  • Stats JSON
  • History CSV (trigger reasons are localized to human-readable text)

All CSVs include UTF-8 BOM, so Windows Excel opens them correctly without character corruption.

Import settings

  1. Choose import mode: Overwrite / Merge
  2. Choose file: JSON (full backup) or CSV (individual)

Auto-backup

  • Enable "Auto-backup" → a backup JSON is downloaded every N hours
  • Customize filename prefix (default yt-filter-backup-)

Share lists

Generate a URL containing selected lists (blocklist / whitelist / keywords / all). Recipients click the URL to quickly import the settings. No server involved (data encoded in URL itself).


🏷️ Tag System

Why tags?

When blocklist or whitelist grows to hundreds of channels, tagging makes management easier:

  • Categories like "Politics", "Sponsored", "Reuploader"
  • Custom groupings like "Trusted", "Watching", "Kid-safe"
  • Tags column in exported CSV enables offline categorization

Adding tags

Method A: Quick panel via 🏷

  1. Hover channel entry → click 🏷
  2. The panel expands into two sections:
    • 📝 Add tag — enter new tag + press Enter or click +
    • 📌 All tags (✓ owned, click to toggle) — all system tags as chips, click to toggle state

Method B: Edit form

Click ✏️ to open the edit form. The "tags" field accepts comma-separated input. Below the input, an "📌 All tags" chip row lets you click to toggle.

Filtering

Each list has a tag filter bar at the top:

  • All (200) → show all entries
  • Politics (15) → show only entries tagged "Politics"

Important rules

Item Description
Tag isolation Blocklist tags vs Whitelist tags are completely independent, even if named identically
Real-time sync All related UI refreshes instantly after adding/removing tags
Auto-reset on empty filter If a filtered tag is removed entirely, the list auto-returns to "All"

🔍 Complete Regex Guide

When to use Regex

Enable ⌥R.* Regex mode in blocklist/whitelist entries or keyword groups. Use it for:

  • Prefix / suffix matching
  • Batch naming patterns (EP1 / EP.1 / EP 1 etc.)
  • Avoiding partial matches (e.g., match "NASA" but not "NASA-related")

Case-insensitive by default.

Common syntax

Pattern Description
^abc Starts with abc
abc$ Ends with abc
`a\ b`
\d+ One or more digits
\b Word boundary (avoids partial match)
.* Any characters (zero or more)
[0-9] Character range

Practical examples

Pattern Matches
^\[Ad\] All videos with titles starting with "[Ad]"
\bNASA\b Standalone NASA (avoids "NASA-related")
`(stocks\ investing\
EP\.?\d+ Matches EP1 / EP.1 / EP 1 episode formats
^(?!.*official).*$ Titles that do NOT contain "official" (negative lookahead)

Tips

No need to add / slashes or /i flags — just enter the pattern. Backslash escaping is handled by the UI.


🛡️ Child Safety Setup Example

Build a child-friendly browsing environment using existing features:

6 Steps

Step 1 | Whitelist: Go to ⭐ Whitelist tab, add child-safe channels (e.g., @PBSKids, @SesameStreet, @CocomelonOfficial)

Step 2 | Whitelist-only: Go to ⚙️ Settings (top), enable "⭐ Show only whitelisted channels" — everything else will be hidden

Step 3 | No live streams: In "📡 Live / Premiere" section, enable "Hide live streams" and "Hide upcoming premieres" — avoids live chat risks

Step 4 | Keyword blocklist: In 🔤 Keywords, create a "Harmful content" group with words like "violence, gore, horror, adult, gambling" and enable it (regex: (violence|gore|horror|adult|gambling))

Step 5 (optional) | Date limit: In 📅 Upload date, set "Hide videos older than 30 days" — prevents algorithm pushing old controversial content

Step 6 (optional) | Language filter: In 🌐 Language filter, select "Show only selected languages" and check only the child's native language

⚠️ Important disclaimer

This script only filters listing pages (home / search / recommendations). It cannot:

  • Block direct URL access
  • Detect actual video content (only reads metadata)

Strongly recommended additions:

  • YouTube Kids app
  • Parental control software (Google Family Link, etc.)
  • Router-level DNS filtering (CleanBrowsing, NextDNS, etc.)

⌨️ Keyboard Shortcuts & Quick Actions

Action Behavior
Top bar 🔍 button left-click Open management panel
Top bar 🔍 button right-click Toggle filter on/off (temporarily see raw YouTube)
Video card hover Bottom slides out "🚫 Block" & "⭐ Whitelist" buttons
Tampermonkey menu Provides "Open panel", "Toggle filter", "Backup settings now" options

Debug mode

Enable via Tampermonkey menu "🔍 Toggle debug mode":

  • Browser console shows detailed logs
  • Run __ytfReport() to view statistics
  • Keep disabled during normal use to avoid noise

FAQ

Q: Tampermonkey doesn't detect the new version?

Delete the old version → install the new one. Verify the loaded version via the top-right version badge in the panel.

Q: Exported CSV shows garbled Chinese in Excel?

Verify version is v1.1.0 or higher (UTF-8 BOM fix). If still garbled, use Excel's "Data → From Text" with UTF-8 encoding.

Q: Language detection is inaccurate?

Latin-based languages (English, Spanish, Vietnamese, French) have lower accuracy due to character overlap. Combine with keyword filters for more precise results.

Q: Whitelisted channel still gets blocked?

Possible causes:

  1. Channel ID or name has inconsistent spelling (including case)
  2. The channel is a playlist / YouTube Mix (not single-channel content)
  3. If using Regex, verify the pattern matches correctly

Q: Why can't some video tags be filtered by keywords?

Keywords only match visible title and description. If a video's description is collapsed or truncated by YouTube, description matching may fail. Always include "Title" in the scope.

Q: Where is data stored?

  • ytf_bl / ytf_wl / ytf_kg / ytf_fl / ytf_gl: lists and settings
  • ytf_st / ytf_hi: stats and history
  • ytf_vcm: videoId→channelId cache
  • ytf_lang: interface language

All data is stored in Tampermonkey's GM Storage. Nothing is uploaded to any server.


Links