Skip to content

Instantly share code, notes, and snippets.

@cr2007
Created January 29, 2026 15:00
Show Gist options
  • Select an option

  • Save cr2007/3ff04156bb1b5948877ecb8079323228 to your computer and use it in GitHub Desktop.

Select an option

Save cr2007/3ff04156bb1b5948877ecb8079323228 to your computer and use it in GitHub Desktop.
Video Adjustable Hacks

Using the Web Audio API in the console, it is possible to boost the volume beyond 100%.

Standard volume controls are capped at 1.0 (100%), but this method creates a "virtual amplifier" for the audio stream.

Volume Boost

(function() {
    const video = document.querySelector('video');
    if (!video) return console.log("No video found. Try switching console context to the iframe.");
    
    // Create audio context and nodes
    const audioCtx = new (window.AudioContext || window.webkitAudioContext)();
    const source = audioCtx.createMediaElementSource(video);
    const gainNode = audioCtx.createGain();
    
    // Set gain (2 = 200%, 3 = 300%, etc.)
    gainNode.gain.value = 3; 
    
    // Connect the chain
    source.connect(gainNode);
    gainNode.connect(audioCtx.destination);
    
    console.log("Volume boosted! Current gain: " + gainNode.gain.value);
    window.gainNode = gainNode; // Store globally so you can change it later
})();

Adjust on the fly

Once the script is running, you can change the volume further by typing:

gainNode.gain.value = 5; // (replaces 5 with your desired multiplier).
// Adjusting Video Speed Manually (all the way to 16x)
// Can use to quickly speed up YouTube Ads by setting the speed to 16x
// Decimal input, so can specify it to any particular
document.querySelector('video').playbackRate = 16;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment