Vertical side scroll progress bar with a purple to red gradient effect that fills based on scroll depth using vanilla JavaScript

Gradient Vertical Scroll Progress Bar

This is a Gradient Vertical Scroll Progress Bar. It maps the user’s vertical position to a visual meter along the right edge of the viewport. Its function is to provide an unobtrusive sense of reading progress without cluttering the main content area.

Technologies:
HTML CSS JavaScript
Difficulty: Beginner
Browser Support (as of Mar 2026):
Chrome Chrome 61+ Edge Edge 17+ Firefox Firefox 64+ Safari Safari 11+
Features:
Scroll Tracking Gradient Fill Dynamic Opacity
Code by: Emma Bostian Emma Bostian
License: MIT

This advanced CSS demo uses @layer for structure and achieves cross-browser scrollbar customization with theme-aware coloring via color-mix and light-dark; it integrates experimental features like CSS Anchoring and the ::scroll-button(*) pseudo-element for customizable scroll arrows, ensuring accessibility through enhanced :focus-visible feedback on the custom thumb.

A scroll progress indicator effect created with a clever CSS trick - a massive box-shadow with a negative offset on ::-webkit-scrollbar-thumb creates the illusion of filling the traversed track as you scroll.

Dashboard Layout Design - iPad Pro

Dashboard Layout Design - iPad Pro

The interface includes a responsive sidebar, a sticky header, and a scrollable grid of cards with custom progress bars and status indicators, ensuring a polished, app-like user experience without relying on JavaScript.