Vortex Background Component is a single JavaScript file, vortex.js, that adds a swirling ring of up to 160,000 GPU particles behind any section of your site. Call Vortex.create() or add a data-vortex attribute and it appends a click-through canvas, handles sizing, pointer interaction, pausing and cleanup for you.
The download also includes a complete landing page that doubles as documentation: a hero using the component, a feature overview, a playground with sliders for particle count, speed, radius, thickness, size, brightness, interaction and colours that generates your configuration snippet live, an options reference table, install steps and an FAQ.
The component is written in raw WebGL with its own tiny matrix maths, so there are no libraries, no CDN calls and no build step. It is honest about being a lightweight effect, not a general 3D engine: one scene, one ring, tuned well. If WebGL is unavailable a Canvas2D renderer takes over with a capped particle count.
Highlights
- Single file (21 KB, 7 KB gzipped), zero dependencies, works from file://
- Options API: count, colors, speed, radius, thickness, size, opacity, interaction, parallax, offset, blend
- Repel / attract / off pointer interaction with smooth falloff, touch supported
- Live playground with sliders, colour presets, shuffle and a one-click copy snippet
- Pauses when the tab is hidden or the section is offscreen; freezes for prefers-reduced-motion
- Canvas2D fallback when WebGL is missing; devicePixelRatio capped
- Dark and light page theme with toggle, responsive 360px to 1920px
mammoth templates


