Orbital Loader, animated React component
A loader with a comet that laps the ring, speeding up and easing off each lap, its tail stretching with the speed and shrinking as it slows. Give it progress and the arc fills behind the comet; at 100% the ring pops, turns green and draws a tick. Also includes Step Loader: For long jobs: the current step sits centred, finished ones roll up with a tick, a ring shows progress, Cancel is always there, and it ends on the result.
- Free
- Loaders
- Spring
The Step Loader variant ticks as each step finishes (every step, or every second one when the run is fast), plays a done chime when the result appears, and makes a soft off sound when you press Cancel. Sound is off on this site until you switch it on.
Progress
Endless
Step Loader
Like Orbital Loader? 256 more are in Pro.
Pro unlocks all 256 Pro components, every template and block, and everything we release next. Orbital Loader stays free.
Play with it
Move the controls and watch it change. Copy code gives you a snippet with only the props you changed.
Uploading your files…
Props
| Prop | Type | Default | What it does |
|---|---|---|---|
| progress | number | — | 0–1 for a ring that fills to progress; leave out for an endless orbit. At 1 it ticks. |
| size | number | 112 | Diameter in px. |
| messages | string[] | ["Warming up the build", ...] | Status lines cycled under the loader. One line stays fixed; [] hides them. |
| doneMessage | string | "Done" | Line shown once progress reaches 1. |
| color | string | — | Accent colour of the arc and comet. Defaults to system blue. |
| onComplete | () => void | — | Called once when progress reaches 1. |
| autoplay | boolean | false | Runs a pretend upload from 0 to 100%, ticks, and starts again, until someone clicks the loader. |
| className | string | — | Classes for the root. |
| StepLoader.steps | string[] | STEP_LOADER_STEPS | The steps of the job, in order. The last one shows briefly as done before the result appears. |
| StepLoader.stepMs | number | 1050 | How long each step stays current, in ms. Under 800 the finish tick plays on every second step instead of every step. |
| StepLoader.title | string | "Set up your workspace" | Heading shown before the job starts. |
| StepLoader.idleText | string | "This takes about six seconds." | Line under the heading before the job starts. |
| StepLoader.startLabel | string | "Start setup" | Label of the button that starts the job. |
| StepLoader.doneTitle | string | "Your workspace is ready" | Heading of the result once every step has finished. |
| StepLoader.doneText | string | "248 customers imported, dashboard built, 3 invites sent." | Line under the result heading. |
| StepLoader.actionLabel | string | "Open workspace" | Label of the button on the result. |
| StepLoader.onComplete | () => void | — | Called once when every step has finished. |
| StepLoader.onCancel | () => void | — | Called when Cancel is pressed. |
| StepLoader.onAction | () => void | — | Called when the button on the result is pressed. |
| StepLoader.autoplay | boolean | false | Starts the job by itself, shows the result, and starts again, until someone touches the card. Pauses off screen and never runs under reduced motion. |
| StepLoader.enableSound | boolean | true | Ticks as steps finish, plays a done sound at the end and a soft off on Cancel. Follows the site-wide sound switch; autoplay makes the same sounds once the visitor has used the page. |
| StepLoader.className | string | — | Extra classes for the card. |
| enableSound | boolean | true | Plays interface sounds on interaction. They follow the sound switch (setSoundsEnabled, on by default) and stay silent on hover. Autoplay makes the same sounds once the visitor has used the page. Pass false to silence this component. |
Add it to your project
- 1
Set up your project once
You need a Next.js project with Tailwind CSS and the
@/import alias. In its root folder, run this once. It createscomponents.jsonand thecn()helper insrc/lib/utils.ts:npx shadcn@latest init -d
Starting from nothing? The Quick Start walks through the whole thing.
- 2
Connect the registry
Run this once per project. It writes the Nexus UI entry into
components.jsonfor you:npx shadcn@latest registry add "@nexus-labs=https://www.nexus-ui.com/api/registry/{name}"Type it exactly as shown.
{name}is filled in by the CLI with the component you ask for, so you never replace it.
- 3
Add the component
Run this from your project root. It adds the component, the helpers it imports and its npm packages.
npx shadcn@latest add @nexus-labs/orbital-loader
- 4
Check what was added
With a project made as in the Quick Start (a
src/folder), these files land in it:components/orbital-loader/index.tsorbital-loader.tsxstep-loader.tsx - 5
Copying by hand? Skip the registry
Instead of steps 2 and 3 you can copy the files yourself, with no registry and no API key. Step 1 still applies, so that
cn()exists. Install the packages:npm install framer-motion
Then show the source and create each file at the path it gives:
- 6
Use it in a page
Installing only adds the files. Import the component in a page and render it. The Usage tab on the preview shows a fuller example with props:
// src/app/page.tsx import { OrbitalLoader } from "@/components/orbital-loader"; export default function Page() { return ( <main> <OrbitalLoader /> </main> ); }
Like Orbital Loader? 256 more are in Pro.
Pro unlocks all 256 Pro components, every template and block, and everything we release next. Orbital Loader stays free.
About Orbital Loader
The Orbital Loader is a dual counter-rotating ring loading indicator with an independently pulsing inner glow. The outer and inner rings rotate in opposite directions using CSS animation, producing a hypnotic orbital effect with no JavaScript overhead. The center glow breathes on a separate animation cycle. Use it as a page loader, section skeleton replacement, or inline loading indicator for async operations in any React application.
Good for
- Page and route loading states
- API fetch and data loading indicators
- Form submission spinners
- Async operation feedback indicators
Orbital Loader questions
Can it show real progress instead of spinning?
Yes. Pass `progress` as a number from 0 to 1 and the arc fills to that value with a percentage in the middle. Leave it out for an endless sweeping arc.
How do I change the loading messages?
Pass `messages` as an array of strings; they rotate every 1.8 seconds. Pass a single string for a fixed label, or an empty array to hide the text.
How do I change the size and color?
`size` sets the diameter in pixels (default 112) and `color` sets the arc and orbiting dot color (default #6366f1).
Is the orb loader accessible?
It renders with role="status" and aria-live="polite", so the status text is announced, and the spinning stops when the user prefers reduced motion. It also has dark mode styles.
Does it make sound, and how do I turn it off?
The Step Loader variant ticks as each step finishes (every step, or every second one when the run is fast), plays a done chime when the result appears, and makes a soft off sound when you press Cancel. Sounds are synthesised with the Web Audio API, so there are no audio files, and they only play after a click or key press. Pass `enableSound={false}` to silence this component, or call `setSoundsEnabled(false)` from `@/lib/ui-sounds` to switch every sound off at once. The CLI installs `@/lib/ui-sounds` with the component.