A lightweight Chrome extension that hides YouTube Shorts from your browsing experience.
| Surface | What gets hidden |
|---|---|
Home feed (/) |
Shorts shelf/section |
Subscriptions (/feed/subscriptions) |
Shorts shelf/section |
Search results (/results) |
Shorts shelf + individual Shorts entries |
Watch page (/watch) |
Shorts in sidebar recommendations |
| Left sidebar | "Shorts" navigation link |
- Creator channel Shorts tabs/sections
- Per-surface toggle (single global on/off only)
- Redirecting or rewriting
/shorts/URLs
- Clone or download this folder.
- Open Chrome →
chrome://extensions/. - Enable Developer mode (top-right toggle).
- Click Load unpacked and select the cloned folder (the one with
manifest.json). - The red circle icon should appear in your toolbar.
Click the extension icon to open the popup. Use the toggle to enable or disable filtering. Changes take effect immediately without reloading the page.
- A content script (
src/content.js) runs on every YouTube page. - It detects the current page type and hides Shorts-related elements using CSS
display: none. - A MutationObserver re-scans when YouTube dynamically loads new content.
- YouTube SPA navigations are detected via the
yt-navigate-finishevent plus a URL-polling fallback. - Elements are hidden (not deleted) so the extension can cleanly reverse its changes when disabled.
All YouTube-specific selectors are centralized in src/selectors.js. Detection favors:
/shorts/in link hrefs — the most stable signal- "Shorts" text in shelf titles — catches labeled sections
- Renderer tag names (
ytd-reel-shelf-renderer,ytd-rich-shelf-renderer) — YouTube's component names
When YouTube changes its markup, update src/selectors.js first.
When enabled, the extension logs to the console with a [NoShorts] prefix:
- SPA navigation detected — route change detected and filters reapplied
- N Shorts hidden on "surface" — periodic count (every 30 s)
- Enabled on "surface" but 0 Shorts hidden — possible selector breakage
.
├── manifest.json # MV3 extension manifest
├── src/
│ ├── content.js # Main filtering engine
│ ├── selectors.js # Centralized selector definitions
│ └── state.js # Storage-backed enabled state
├── popup/
│ ├── popup.html # Toggle UI
│ ├── popup.js # Popup logic
│ └── popup.css # Popup styles
├── icons/
│ ├── icon16.png
│ ├── icon48.png
│ └── icon128.png
└── README.md
- Add route detection in
currentSurface()insidesrc/content.js. - Add selectors/heuristics in
src/selectors.js. - Add a filter function in
src/content.jsand call it fromrunFilters(). - Update this README.
MIT. See LICENSE.
Not affiliated with or endorsed by YouTube or Google.