Skip to content

Instantly share code, notes, and snippets.

@neon-dev
Last active August 17, 2025 03:53
Show Gist options
  • Select an option

  • Save neon-dev/e46ff0765caa09f8417ef6bb44450f70 to your computer and use it in GitHub Desktop.

Select an option

Save neon-dev/e46ff0765caa09f8417ef6bb44450f70 to your computer and use it in GitHub Desktop.
Userscript that prevents YouTube and YouTube Music from pausing playback. It uses a simple solution from https://github.com/lawfx/YoutubeNonStop/pull/43#issuecomment-954689654, which, unlike YouTube NonStop, does not resume paused content unintentionally.
// ==UserScript==
// @name YouTube NonStop Simple
// @namespace https://gist.github.com/neon-dev
// @version 0.1
// @description Prevents YouTube and YouTube Music from pausing playback. It uses a simple solution from https://github.com/lawfx/YoutubeNonStop/pull/43#issuecomment-954689654, which, unlike YouTube NonStop, does not resume paused content unintentionally.
// @author Neon
// @match https://www.youtube.com/*
// @match https://music.youtube.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=music.youtube.com
// @updateURL https://gist.github.com/neon-dev/e46ff0765caa09f8417ef6bb44450f70/raw
// @downloadURL https://gist.github.com/neon-dev/e46ff0765caa09f8417ef6bb44450f70/raw
// @grant none
// ==/UserScript==
(function() {
'use strict';
setInterval(() => {window._lact = Date.now()}, 900000);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment