Swup is a page transition library that adds smooth animations between pages on server-rendered websites without requiring a single-page app architecture.
The library solves the problem of making traditional server-rendered sites feel responsive and modern by managing the complete page load lifecycle. It automatically detects CSS transitions and animations to time them perfectly, then smoothly animates between the current and next page while handling URL updates, browser history, scroll position management, and page caching. The approach requires minimal markup and works out of the box, letting developers add snappy page transitions to existing server-rendered sites without architectural complexity.
Swup suits teams maintaining traditional server-rendered websites who want to improve perceived performance and user experience without migrating to a single-page app framework. The tool is intentionally small by design, with extended features available through a plugin system that includes official plugins for progress bars, smooth scrolling, meta tag updates, page preloading, accessibility improvements, JavaScript-based animations, form submission handling, and debug mode. The project also provides three ready-made themes—fade, slide, and overlay—to accelerate initial setup.
The project maintains active engagement with its community through discussions and maintains comprehensive documentation covering getting started, hooks for customization, and the plugin ecosystem. Development activity shows consistent attention to the codebase with regular updates and refinements to the core library and its plugin ecosystem.