Enhance your site’s visual appeal with JavaScript parallax effects that create a sense of depth and motion. This collection features examples of scroll-based animations, layered backgrounds, and interactive mouse-driven scenes - ideal for landing pages, portfolios, and modern web designs.
51 JavaScript Parallax
Draggable Image Track Parallax
demo & codeThis is a Draggable Image Track Parallax component. It replaces standard scrollbars with a custom, click-and-drag horizontal interface. Its function is to provide a highly kinetic, app-like browsing experience for image galleries, featuring an internal parallax effect where the images pan slightly inside their frames as the entire track moves.
Interactive Vertical Parallax Cursor Navigation
demo & codeThis is an Interactive Vertical Parallax Cursor Navigation. It combines large-scale typography with a dynamic image-reveal system. Its function is to provide an immersive, tactile menu experience for high-end creative portfolios, where the user’s cursor physically “steers” the list and uncovers visual content linked to each item.
Mouse-Reactive Floating Image Gallery
demo & codeThis is a Mouse-Reactive Floating Image Gallery. It places an oversized grid of visual assets behind the viewport, hidden by the overflow. Its function is to provide an immersive, explorative navigation experience where the user’s cursor physically steers the scene across a scattered landscape of content.
Cinematic Parallax Reactive Navigation Menu
demo & codeThis is a Cinematic Parallax Reactive Navigation Menu. It synchronizes large-scale typographical navigation with multi-layered background shifts. Its function is to transform a standard menu into a high-end atmospheric gateway for editorial or premium portfolio websites, using user interaction to drive the visual narrative.
Shattering Image Gallery Transition
demo & codeThis is a Shattering Image Gallery Transition. It utilizes the WebGL API via Three.js to deconstruct 2D images into a matrix of 3D particles. Its function is to replace standard fade or slide slideshows with a highly cinematic, physics-based explosion effect, transitioning between photographs by blowing the current image apart to reveal the next one underneath.
Smooth 3D Scroll-Driven Reveal
demo & codeThis is a Smooth 3D Scroll-Driven Reveal. It replaces the native scroll behavior with a custom, momentum-based scrolling engine that orchestrates complex 3D transforms. Its function is to create a gallery experience where images feel weightless, tilting and translating in 3D space based on their velocity and position relative to the viewport.
Pinned Split-Screen Mask Reveal
demo & codePinned Split-Screen Mask Reveal is a high-performance scroll-driven layout. It synchronizes fixed image stacks with flowing text content. This element creates a cinematic transition where images are “unmasked” as the user progresses through sections. It is designed to bridge the gap between static information and immersive visual storytelling.
Canvas Card Slicer Game
demo & codeModern web games often rely on bloated frameworks. This project demonstrates the raw capability of the native Canvas API combined with lightweight physics. It is a satisfying, tactile experience where the user’s cursor becomes a blade. By implementing a custom particle system and separating the collision logic (SAT.js) from the rendering, we achieve a high-performance arcade feel that runs smoothly even on modest hardware.
3D Parallax Card Slider
demo & codeThis 3D Parallax Card Slider brings a tangible, high-fidelity feel to web galleries. It goes beyond simple sliding by implementing a physics-based tilt effect that reacts to mouse movement, giving each card weight and depth. The background adapts seamlessly to the active slide, creating an immersive atmosphere perfect for luxury travel sites or premium portfolios.
Parallax Jungle Leaves Reveal
demo & codeThis Parallax Jungle Leaves Reveal creates a cinematic opening for a landing page. As the user scrolls, dense layers of tropical SVG leaves part ways - some moving left, some right - while smaller leaves float randomly in the background. The effect culminates in the reveal of a typography-based logo, creating a sense of depth and discovery perfect for storytelling or adventure-themed websites.
Scroll-Driven Image Swapper
demo & codeThis Scroll-Driven Image Swapper demonstrates the bleeding edge of web animation. It uses the native CSS Scroll-driven Animations API to create a complex parallax-like effect where two columns of different heights scroll in sync. As you scroll, the images in the shorter column slide and crossfade to match the context of the taller column. Crucially, the code implements a Progressive Enhancement strategy: it checks for native browser support and falls back to GSAP ScrollTrigger for browsers that haven’t implemented the spec yet.
Draggable 3D Parallax Image Ring
demo & codeThis Draggable 3D Parallax Image Ring creates a high-end, immersive gallery experience often associated with WebGL, but built entirely with DOM elements and GSAP. It arranges images in a 3D circle that users can spin with a swipe or mouse drag. The standout feature is the calculated parallax effect: as the ring rotates, the background position of each image shifts in the opposite direction, creating a convincing illusion of depth and window-like transparency.
Interactive 3D Photo Cube
demo & codeThis Interactive 3D Photo Cube creates a spatial navigation experience where a user explores six images mapped onto a cube by moving their cursor. Unlike standard sliders, it utilizes CSS 3D transforms orchestrated by GSAP to create a seamless, physics-like rotation. The snippet also features a “window-pane” parallax effect where the background images shift slightly inside their frames, adding an extra layer of depth.
ScrollMagic Pizza Assembly Animation
demo & codeThis ScrollMagic Pizza Assembly Animation transforms a standard product landing page into an interactive storytelling experience. As the user scrolls down, individual pizza ingredients - peppers, mushrooms, olives - fly in from different directions to assemble a complete pizza. The sequence is tightly choreographed using GSAP timelines pinned to the scroll position, giving the user direct control over the “cooking” process.
Smooth Parallax Scroll Layout
demo & codeThis GSAP ScrollSmoother Parallax Gallery represents a high-end implementation of scroll-based storytelling suitable for portfolios or luxury brand landing pages. It leverages the full power of the GreenSock ecosystem - specifically the premium ScrollSmoother and SplitText plugins - to create a “buttery” smooth scroll experience where content reveals itself with elegant, staggered animations and depth-inducing parallax.
Perspective Zoom Effect on Scroll
An immersive scrolling experience where the user flies through a cloud of photos that smoothly approach and fade away, revealing an elegantly emerging text.
See the Pen Perspective Zoom Effect on Scroll.
GSAP ScrollSmoother and Three.js
An immersive scrolling experience blending smooth typography with a floating 3D particle field powered by Three.js. GSAP orchestrates the camera movement and dynamic text highlighting, creating a synchronized parallax journey.
See the Pen GSAP ScrollSmoother and Three.js.
Scroll UI Animation
As you scroll down, a large image of a field shrinks and gets cropped by white blocks to focus attention, while a heading on the left counts up the percentage of water saved, changing color for emphasis. This creates the feel of a dynamic infographic.
See the Pen Scroll UI Animation.
Smooth Scrolling with GSAP ScrollSmoother
A premium smooth-scrolling interface orchestrated by GSAP’s ScrollSmoother plugin. The layout leverages CSS Grid for overlapping compositions, while declarative data-speed attributes drive distinct parallax velocities for text and imagery, creating a layered, depth-rich browsing experience.
See the Pen Smooth Scrolling with GSAP ScrollSmoother.
Holographic Name Card with Hover Effects
An interactive 3D holographic card where JavaScript maps pointer coordinates to scoped CSS Custom Properties like --pointer-x. The physical lighting simulation relies on complex gradient layering, mask-image, and mix-blend-mode, all dynamically driven by these calculated values to create realistic depth and glare.
See the Pen Holographic Name Card with Hover Effects.
Amateur Radio Badge 3D
A highly sophisticated holographic badge simulation utilizing CSS 3D transforms and layered mix-blend-mode effects. JavaScript tracks mouse movement to dynamically update CSS variables, driving complex parallax shifts, lighting gradients, and SVG-masked glares for a realistic, tactile depth experience.
See the Pen Amateur Radio Badge 3D.
Air Balloon Cruise
A soothing dreamscape scene with smooth, infinite animation resembling a live postcard or a splash screen for a meditation app.
See the Pen Air Balloon Cruise.
3D Patronus Magic Card
An enchanting 3D parallax card featuring a multi-layered depth effect driven by mouse interaction.
See the Pen 3D Patronus Magic Card.
Parallax Carousel with GSAP Observer
Images drift horizontally at varying speeds and sizes, establishing a tangible sense of depth. Upon user interaction, the scroll accelerates or reverses direction with a satisfyingly elastic, spring-like response.
See the Pen Parallax Carousel with GSAP Observer.
Day and Night Toggle with SVG Animation
An atmospheric day/night toggle where a minimal JavaScript classList.toggle trigger activates a cinematic transition across complex SVG layers. The scenery leverages linear-gradient masking and mix-blend-mode for dynamic lighting, while long-duration CSS transform properties orchestrate a seamless, parallax-like shift between solar and lunar states.
See the Pen Day and Night Toggle with SVG Animation.
Inertial Scroll Gallery with 3D Transforms
A sophisticated scroll-hijacking gallery that emulates inertia using a virtual scroll container and requestAnimationFrame. JavaScript orchestrates complex 3D transforms - calculating rotation and translation based on intersection ratios - while the layout relies on a fixed CSS grid.
See the Pen Inertial Scroll Gallery with 3D Transforms.
Interactive 3D Tilt Hover Effect
An interactive 3D card selector featuring a dynamic parallax effect where cards rotate in perspective based on mouse coordinates. JavaScript calculates angular transforms and constraints for a ‘chef’ character that playfully follows the cursor along the card’s axis.
See the Pen Interactive 3D Tilt Hover Effect.
GSAP ScrollTrigger Parallax Effect
This demo is a masterclass in scroll-driven animation, where GSAP’s ScrollTrigger plugin choreographs multiple, layered effects. A fluid parallax effect is created by using scrub: 1 to tie the yPercent and rotation of decorative elements directly to the scrollbar. This is complemented by a sophisticated text reveal, where GSAP’s SplitText plugin animates characters into view with a staggered opacity and y tween, demonstrating a powerful and modular approach to building complex, interactive scrolling experiences.
See the Pen GSAP ScrollTrigger Parallax Effect.
Horizontal Scroll Section with GSAP and Locomotive Scroll
Experience a classic “pinned” horizontal scroll effect, where a vertical scroll action is converted into horizontal movement. GSAP’s pin: true property freezes the section in place, while a tween animates the x property of the inner container, creating a cinematic, side-scrolling gallery.
Illustration Parallax on Hero Section
A parallax effect with GSAP ScrollTrigger - as the page scrolls, a trigger animates the Y-coordinate of several image layers, creating a sense of depth, with movement smoothness defined by a CustomEase.
See the Pen Illustration Parallax on Hero Section.
Interactive Super Mario Timeline with Parallax
An interactive timeline where JS synchronizes CSS transform: translateX for scrolling, background-position for parallax, and classes for sprite animation.
See the Pen Interactive Super Mario Timeline with Parallax.
Super Mario Scrollytelling Timeline with GSAP
Classic ‘scrollytelling’ with GSAP - creating the illusion of movement by animating transform: translateX on position: fixed elements based on the vertical scroll of an extra-long page.
See the Pen Super Mario Scrollytelling Timeline with GSAP.
Marvel Snap Card Pseudo-3D Effect
A pseudo-3D card effect that mimics the “split parallax” technique using multiple image layers and the key transform-style: preserve-3d property; the card’s dynamic tilt (rotateY/rotateX) is driven by vanilla JavaScript based on cursor/touch position.
See the Pen Marvel Snap Card Pseudo-3D Effect.
Cards with Parallax Tilt Effect
Dive into a stunning card effect utilizing CSS 3D transforms and precise mouse tracking to create a realistic, multi-layered depth and parallax illusion on hover.
See the Pen Cards with Parallax Tilt Effect.
Horizontal Parallax Sliding Slider with Swiper.js
A horizontal parallax slider built on Swiper.js, featuring a unique navigation system where a vertical preview slider is fully synchronized with the main one, providing a comfortable and stylish viewing experience.
See the Pen Horizontal Parallax Sliding Slider with Swiper.js.
Full Screen Image Reveal Effect
A high-performance interface that uses TweenMax (part of GSAP) to apply micro-interactions (smooth parallax on titles and images on hover) and create a dramatic “fly-out” effect using Power3.easeIn during the state transition.
See the Pen Full Screen Image Reveal Effect.
Photo Gallery with a Comic Touch
Explore a dual-interaction card where a 3D parallax responds to mouse movement, while a click triggers a “camera flash” and a comic-style text reveal. The hover effect uses throttled JS for performance, and the click animations are powered by GSAP.
See the Pen Photo Gallery with a Comic Touch.
Light and Shadow Mouse Tracking
A showcase of powerful interactive styling, where JS logic calculates cursor distance and direction to control a moving shadow and the intensity of a border glow via CSS variables and pseudo-elements.
See the Pen Light and Shadow Mouse Tracking.
Parallax Effect with Text Blend Mode
A spectacular mouse-controlled Parallax effect implemented using the Parallax.js library and data-depth attributes that define the movement speed of each layer. This is a key example for creating deep 3D interaction and using mix-blend-mode for text styling.
See the Pen Parallax Effect with Text Blend Mode.
Shine Foil Card
A simple yet elegant implementation of an interactive “3D card” hover effect. The code uses getBoundingClientRect() to calculate the element’s center and then applies an offset to inner layers, achieving a parallax effect with just a few lines of JavaScript and CSS.
See the Pen Shine Foil Card.
Parallax Slider with Vanilla JS
A clever JS-driven slider that uses a custom checkPosition function to dynamically scale each image in real-time. This parallactic effect, combined with a smooth-scrolling overflow and changing background images, creates a highly immersive visual experience.
See the Pen Parallax Slider with Vanilla JS.
Modern Slideshow with Vanilla JS
This animated slider is built with vanilla JavaScript and CSS, offering a rich UX with arrow, click, and swipe navigation, plus a seamless auto-play and progress bar.
See the Pen Modern Slideshow with Vanilla JS.
Parallax TechTrades™ Holographic Trading Card
A feature-rich web animation showcasing an interactive 3D card with a hover-based parallax effect, a card-flipping animation, and dynamic SVG drawing and lighting effects all orchestrated by the powerful GSAP library.
See the Pen Parallax TechTrades™ Holographic Trading Card.
Repetition Image Animation
Technically, this GSAP and vanilla JS demo creates a multi-layered parallax effect, where each layer responds to mouse movement, and a drag gesture adds complex 3D rotation. The code is flexible, allowing you to switch between different shapes and visual styles.
See the Pen Repetition Image Animation.
Kinetic Brutalism: A 3D Parallax Effect
A showcase of the synergy between JavaScript and CSS to create a detailed 3D element with a parallax effect. It uses requestAnimationFrame for performance-optimized calculation of velocity and position, and transform-style: preserve-3d for correct layer rendering.
See the Pen Kinetic Brutalism: A 3D Parallax Effect.