Skip to content

Floating Orbs

A copy-paste backgrounds component in pure HTML & CSS. Zero dependencies, framework-agnostic, MIT-licensed.

BackgroundsHTMLCSSany framework

Copy into your project

HTML
<div class="nuda-float-orbs" aria-hidden="true">
  <span class="nuda-float-orbs__o nuda-float-orbs__o--1"></span>
  <span class="nuda-float-orbs__o nuda-float-orbs__o--2"></span>
  <span class="nuda-float-orbs__o nuda-float-orbs__o--3"></span>
</div>
CSS
.nuda-float-orbs {
  position: relative;
  overflow: hidden;
  background: #09090b;
  isolation: isolate;
}

.nuda-float-orbs__o {
  position: absolute;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  filter: blur(34px);
  opacity: .5;
  mix-blend-mode: screen;
  will-change: transform;
}

.nuda-float-orbs__o--1 {
  background: #e4ff54;
  top: -20px;
  left: 8%;
  animation: _floatOrb 9s ease-in-out infinite alternate;
}

.nuda-float-orbs__o--2 {
  background: #62b6ff;
  bottom: -30px;
  left: 40%;
  animation: _floatOrb 12s ease-in-out infinite alternate-reverse;
  animation-delay: -3s;
}

.nuda-float-orbs__o--3 {
  background: #9d6dff;
  top: 10%;
  right: -10px;
  animation: _floatOrb 14s ease-in-out infinite alternate;
  animation-delay: -6s;
}

@keyframes _floatOrb {
  0% {
    transform: translate(0,0) scale(1);
  }
  100% {
    transform: translate(24px,-20px) scale(1.25);
  }
}

@media (prefers-reduced-motion:reduce) {
  .nuda-float-orbs__o {
    animation: none;
  }
}

How to use Floating Orbs

Paste the HTML where you need it and the CSS into a global stylesheet (or a <style> tag). Every class is prefixed nuda- so it never collides with Tailwind or your own styles. Tweak the CSS custom properties to match your design system.

Works in React, Vue, Svelte, Astro, Next.js, Nuxt, Laravel Blade, Django, Rails — or a single .html file. No npm install, no build step.

More backgrounds components

← Browse all NudaUI components