YouTube Sort by Upload Date

Restores "Sort by Upload Date" functionality to YouTube search using InnerTube API + optional YouTube Data API v3 fallback

Du musst eine Erweiterung wie Tampermonkey, Greasemonkey oder Violentmonkey installieren, um dieses Skript zu installieren.

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

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

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

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

Sie müssten eine Skript Manager Erweiterung installieren damit sie dieses Skript installieren können

(Ich habe schon ein Skript Manager, Lass mich es installieren!)

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.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

Autor
drhouse
Installationen heute
1
Installationen gesamt
463
Bewertungen
1 0 0
Version
1.2.0
Erstellt am
08.03.2026
Letzte Aktualisierung
09.03.2026
Größe
32 KB
Lizenz
CC-BY-NC-SA-4.0
Wird angewandt auf

Post-Launch News

04-18-2026 Ok, got another message with more specifics on what they changed to make it work:

// ─── CONFIG ────────────────────────────────────────────────────────
const SETTINGS_KEY = 'yt_sort_date_settings';
const defaults = { apiKey: 'AIzaSy.....QsizIuRfho', engine: 'dataapi' }; // engine: 'innertube' | 'dataapi'

function getSettings() {
try { return Object.assign({}, defaults, JSON.parse(GM_getValue(SETTINGS_KEY, '{}'))); }
catch { return { ...defaults }; }
}
04-05-2026 Just got a private message today from someone who said they tried using a personal YouTube API Key and the script worked for them. Would be nice to hear from others if this works:

here is the relevant part of his translated message:
"What I should have done was modify the variables at the beginning: I added 'dataapi' and the key. It didn't work with the gear icon and save, but it did work this way."03-08-2026 I've tested this script extensively on my setup, including incognito mode, to rule out conflicts with other extensions or scripts. It works flawlessly for me, but unfortunately others report failures. At this point, all I can do is keep it published... people can try it themselves and see if it works on their end.

YouTube Sort by Upload Date
YouTube removed the ability to easily sort search results by upload date. This userscript brings it back.
When you search for something on YouTube, you'll see a "Sort by Date" button appear near the search filters. Click it and your results will be re-sorted with the newest uploads first. Click it again to go back to YouTube's default ordering.

How it works
The script uses YouTube's own internal search API (InnerTube) to fetch results sorted by upload date - no setup required, it works right out of the box.
If you run into any issues with InnerTube, there's an optional fallback that uses the YouTube Data API v3. To use it, click the gear icon next to the Sort by Date button, select "YouTube Data API v3" as the engine, and paste in your API key. You can get a free key from Google Cloud Console (covers roughly 100 searches per day).

Features
  • One-click sorting by upload date on any YouTube search page
  • Works immediately with no configuration needed
  • Results display in YouTube's native layout style
  • Toggle on and off without losing your original results
  • Optional YouTube Data API v3 fallback if needed
  • Settings are saved between sessions
  • Fully compatible with YouTube's single-page navigation