Overview

GSAP, the GreenSock Animation Platform, is a JavaScript library engineered for creating high-performance, robust web animations and interactive user interfaces. It provides a comprehensive set of tools for animating virtually any property of any object, from DOM elements and SVG to React components, Canvas elements, and generic JavaScript objects. The platform is designed to offer precise control over animation timing, sequencing, and easing, making it a suitable choice for intricate motion graphics and dynamic web experiences.

Developers often select GSAP for projects that demand high reliability and cross-browser compatibility in animation. Its core strength lies in its ability to manage complex animation timelines, enabling developers to sequence multiple animations, control their playback, and synchronize them with user interactions or other events. This timeline-based approach distinguishes it from simpler CSS-based animations, which offer less programmatic control over advanced sequencing and dynamic adjustments. For example, animating a complex UI transition with staggered elements, specific delays, and callbacks at various points is more directly manageable with GSAP's API than with purely declarative methods.

GSAP is particularly well-suited for interactive applications, marketing sites with rich visual storytelling, and games where smooth, responsive animations are critical. Its architecture prioritizes performance, aiming to achieve 60 frames per second (fps) animations even on less powerful devices by optimizing various animation properties and leveraging browser capabilities efficiently. The platform includes a variety of easing functions and plugins that extend its capabilities, such as for scrolling-triggered animations, draggable elements, or complex motion paths. While the core library is available for general public use, advanced plugins and commercial licenses are accessible through paid club memberships, offering additional specialized tools for professional development.

The library's design emphasizes developer experience with a well-documented API and a consistent syntax across its various components. This facilitates learning and integration into existing projects, whether they use vanilla JavaScript or frameworks like React, Vue, or Angular. Its extensibility via plugins means developers can add specialized functionalities without deeply modifying the core animation logic. For instance, the ScrollTrigger plugin allows animations to be precisely linked to scroll position, while MotionPathPlugin simplifies animating objects along complex SVG paths, saving development time on intricate motion design tasks.

Key features

  • High-performance animation engine: Engineered for maximum speed and smooth playback, aiming for 60fps animations across devices and browsers.
  • Timeline-based sequencing: Provides granular control over animation sequences, allowing for precise timing, staggering, and callbacks for complex motion orchestration.
  • Animate anything: Capable of animating HTML elements, SVG, React components, Canvas objects, WebGL, and any generic JavaScript object's properties.
  • Extensible plugin ecosystem: Offers a range of plugins like ScrollTrigger for scroll-based animations, Draggable for interactive elements, and MotionPathPlugin for animating along custom paths.
  • Robust easing options: Includes a comprehensive collection of easing functions for natural and dynamic motion, with customizable options.
  • Cross-browser compatibility: Designed to work consistently across various modern browsers, abstracting away browser-specific animation quirks.
  • Declarative and imperative control: Supports both declarative setups for simple animations and imperative control for complex, dynamic scenarios.
  • Utility methods: Provides helpful utilities for common animation tasks, such as delaying, repeating, and reversing animations.

Pricing

GSAP offers a free core library for general public use, with additional features and commercial licenses available through paid club memberships. Pricing is current as of May 2026.

Tier Description Annual Price Key Benefits
Core Library Basic GSAP functionality for general public and non-commercial use. Free High-performance animation, timeline control, basic eases.
Shockingly Green Club (Personal) For personal projects and individuals. $49 All GSAP plugins (e.g., ScrollTrigger, Draggable, MotionPath), bonus tools, commercial license for personal projects.
Business Green Club (Professional) For individual professionals or small teams. $149 All Shockingly Green benefits, commercial license for professional use (e.g., client projects).
Agency Green Club (Teams) For agencies and larger teams. $399 All Business Green benefits, additional team member access, priority support.

For detailed pricing information and current offerings, refer to the GSAP pricing page.

Common integrations

  • React: GSAP can be integrated with React to animate components, manage complex transitions, and build interactive UIs. The GSAP documentation on React provides guidance on using it with React hooks and lifecycle methods.
  • Vue.js: Developers can use GSAP within Vue.js applications to create dynamic animations and transitions for Vue components. The GSAP documentation for Vue.js offers examples and patterns for integration.
  • Angular: GSAP can be used to enhance Angular applications with custom animations, going beyond Angular's built-in animation modules for more complex scenarios.
  • Svelte: Integrating GSAP with Svelte allows for highly optimized and reactive animations within Svelte applications.
  • Three.js: For 3D web graphics, GSAP is often used in conjunction with Three.js to animate 3D objects, cameras, and scenes, providing precise control over motion.
  • PixiJS: When working with 2D WebGL rendering via PixiJS, GSAP can animate sprites, containers, and other PixiJS objects for game development and interactive experiences.

Alternatives

  • Framer Motion: A production-ready motion library for React that simplifies complex animations and gestures, often preferred for its declarative API within React ecosystems.
  • Anime.js: A lightweight JavaScript animation library that works with CSS, SVG, DOM attributes, and JavaScript objects, known for its small footprint and simple API.
  • LottieFiles: A platform for Lottie animations, enabling developers to use After Effects animations exported as JSON, which can be played natively on web and mobile.
  • CSS Animations: Native browser-based animations defined directly in CSS, suitable for simpler transitions and transformations without JavaScript overhead.
  • Web Animations API (WAAPI): A W3C standard for animating DOM elements directly from JavaScript, offering a programmatic alternative to CSS animations with more control.

Getting started

To begin using GSAP, you can include it via a CDN or install it using a package manager like npm. Here's a basic example that animates a div element's opacity and position:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>GSAP Basic Animation</title>
    <style>
        body { margin: 0; display: flex; justify-content: center; align-items: center; min-height: 100vh; background-color: #f0f0f0; }
        .box { width: 100px; height: 100px; background-color: #007bff; border-radius: 8px; }
    </style>
</head>
<body>
    <div class="box"></div>

    <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/gsap.min.js"></script>
    <script>
        gsap.to(".box", { 
            duration: 2, 
            x: 200, 
            rotation: 360, 
            opacity: 0.5, 
            ease: "power1.inOut" 
        });
    </script>
</body>
</html>

This code snippet includes the GSAP library from a CDN. It then uses gsap.to() to animate the .box element. The animation will run for 2 seconds (duration: 2), move the box 200 pixels along the x-axis (x: 200), rotate it 360 degrees (rotation: 360), change its opacity to 0.5 (opacity: 0.5), and apply an easing function (ease: "power1.inOut") for a smoother start and end to the animation.