Alloy CSS (2026): What It Is, Install and Agent Skill
By Antigravity Skills editorial team · Last updated
Short answer: Alloy CSS is a free, MIT-licensed stylesheet by Fandy Pradana for HTML that your server renders. It gives you utility classes plus dialogs, menus, drawers, tabs, tooltips and toasts that work with JavaScript turned off, and it needs no build step: you link one CSS file from a CDN. It fits Rails, Django, Laravel and htmx, and its repository ships an agent skill so Claude Code, Codex or Antigravity write markup with its classes instead of inventing their own.
Skill page: the agent skill has its own guide, Alloy CSS agent skill: install and use, with the install command and the rules the skill gives your agent.
Unofficial guide. Antigravity Skills is not affiliated with the author. The official sources are alloyhtml.com, the docs at alloyhtml.com/docs and the repository github.com/alloyhtml/css. Facts below were checked on November 19, 2026 against the site, the repository and the npm package, version 1.0.11. The kit is days old and changing fast, so confirm commands at the source.
At a glance
| What it is | One stylesheet of utilities and ready-made parts for server-rendered HTML |
| Author | Fandy Pradana |
| License | MIT |
| Install | A <link> to the jsDelivr CDN, or npm install @alloyhtml/css |
| Size | About 24 KB gzipped for the minified file, per the README |
| Needs | No build step, no framework, no JavaScript for its interactive parts |
| Browsers | Chrome and Edge 135, Firefox 144 and Safari 26.2, and newer, per the site |
| Launch | Show HN post of November 17, 2026 ("Alloy CSS, dialogs, menus and tabs that work with JavaScript off"), 208 points when we checked |
| Agent skill | Yes, in the repository at ai/alloy-css/SKILL.md |
What is Alloy CSS?
Alloy CSS is built for pages that a server turns into HTML: Rails views, Django or Laravel templates, htmx fragments, or a folder of plain HTML files. The README says it also works in React, Vue or Svelte because it is plain CSS, but the interactive parts then no longer need their JavaScript.
The idea is that every page written with it looks like it belongs with the others. The kit holds structure: a fixed set of spacing values, widths, breakpoints and parts. Your taste (colors, fonts, corner radius) goes in one small file of your own that sets the kit's tokens. Dark mode is included as two themes, Dark and Midnight, that you link after the kit.
How to install Alloy CSS
The simplest way is one line in the <head>. This is the link from the official README:
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@alloyhtml/css@1/dist/alloy.min.css">Dark mode that follows the visitor's device is a second, optional link:
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@alloyhtml/css@1/dist/themes/dark.min.css" media="(prefers-color-scheme: dark)">If you prefer to host the file, install from npm and link node_modules/@alloyhtml/css/dist/alloy.min.css, or import the Sass source with @use "@alloyhtml/css/scss/index":
npm install @alloyhtml/cssThe examples on the site use Google's Material Icons, which are not part of the kit. Load them yourself or use another icon set.
What Alloy CSS covers
The docs list every class with a live example. These are the groups, in the order the docs give them:
- Layout and structure: containers (
container-960for pages people read or fill in,container-1320for pages they browse), flex helpers, positioning, hidden, overflow and app layouts. - Sizing and spacing: widths as percentages or fractions, and spacing and radius from a fixed scale, for example
padding-16,margin-top-8androunded-8. - Colors and surfaces: semantic names such as
bg-base,bg-raised,text-primaryandborder-subtlethat follow the theme, plus palette colors for status. - Typography: headings
h1toh6on any element,text-body-1totext-body-4, font weights. - Forms, buttons and tables: fields, checkboxes, radios, switches, buttons and several table styles.
- Interactions without JavaScript: modal, drawer, menu, accordion, carousel, tabs, toggle, toast, tooltip and a copy button.
- Patterns: cards, card grids, panels, pills, stats, avatars, progress bars, search and banners.
Breakpoints go down: a suffix such as -sm applies at 768 px and below, so you write width-50 width-100-sm.
A first page
This markup follows the README's first-page example. The button opens the dialog and Esc or a click outside closes it, with no script on the page:
<button type="button" commandfor="saved" command="show-modal"
class="button bg-primary-1 border-primary-1 text-white hover-bg-primary-2 hover-border-primary-2">Save</button>
<dialog id="saved" closedby="any" class="dialog bg-raised rounded-8 padding-24">
<p class="text-body-1 text-primary margin-bottom-16">Saved.</p>
<button type="button" commandfor="saved" command="close"
class="button bg-surface border-subtle text-primary">Close</button>
</dialog>It relies on the <dialog> element and the commandfor and command attributes, which is why the browser list above starts at recent versions. For a full page, open the official example.html, an invoicing app built with no script, and view its source.
Use Alloy CSS with Antigravity, Claude Code and Codex
An AI agent that has never seen Alloy tends to write Tailwind or Bootstrap class names (mt-4, btn), which Alloy does not define. The project gives you two ways to prevent that.
1. Add the skill. The package includes the skill and a command that copies it into your project. We ran it in an empty folder on November 19, 2026 and it created SKILL.md and reference.md:
# Claude Code: copies to .claude/skills/alloy-css
npx @alloyhtml/css skill
# Antigravity or Codex: choose the folder with --to
npx @alloyhtml/css skill --to .agents/skills/alloy-cssThen ask in plain words, for example: "Build the settings page as server-rendered HTML with Alloy CSS." The skill's own description tells the agent to use it when a project links Alloy CSS or when asked to style markup with Alloy. The skill folder for each agent is explained in How to install skills. The rules inside the skill are on our Alloy CSS skill guide.
2. Point the agent at the reference. The site publishes a plain-text reference at alloyhtml.com/llms.txt with the same rules and every class. You can paste its address into your AGENTS.md or your prompt.
Then check the result. The package has a checker that lists every class in your markup that the kit does not define:
npx @alloyhtml/css check templates/We ran it on a file containing mt-4 and it reported that class and exited with code 1. It reads HTML, ERB, PHP, Twig, Jinja, Vue, Svelte, JSX and several other template types. Pass --css for your own stylesheet and --allow for an icon font's classes.
Limits to know before you use it
- Recent browsers only. The site lists Chrome and Edge 135, Firefox 144 and Safari 26.2. If you must support older browsers, test the dialogs and popovers first.
- A fixed set of values. Spacing, radius and gaps come from a short scale, and there is no
padding-15. One-off sizes go in an inlinestyleattribute. - Young project. The npm package was at version 1.0.11 on the day we checked, with several releases in the preceding days, so details may change.
- Whole-page templates are separate. The site sells an 82-page template pack for $29 on its Templates page. The stylesheet itself is free and MIT-licensed. We have not looked at the templates.
- Not run in production by us. We ran the skill installer and the checker once; we did not build a site with the kit.
FAQ
Is Alloy CSS free?
Yes. The repository and the npm package are under the MIT license, and the stylesheet is free to use.
Does Alloy CSS need a build step?
No. Link the CDN file in your <head>. A build step only appears if you choose to import the Sass source.
Is Alloy CSS the same as Tailwind?
No. Both use utility classes, but Alloy uses its own names (padding-16, flex-gap-16) and also ships ready-made parts such as dialogs, menus and tabs. Tailwind class names will not work in Alloy, and the project's skill and checker exist to catch that mistake.
Does Alloy CSS have an agent skill?
Yes. The official repository contains ai/alloy-css/SKILL.md, and npx @alloyhtml/css skill copies it into your project. We did not find a listing on skills.sh when we checked.
Does Alloy CSS work with React or Vue?
The README says yes, because it is plain CSS, but it is designed for server-rendered HTML where the interactive parts need no JavaScript.
Other products called "Alloy"
Several unrelated projects share the name, among them the Titanium Alloy mobile framework, AlloyUI and the Alloy modeling language. This page is about the stylesheet at alloyhtml.com.
Related guides
- Alloy CSS agent skill: install and use
- How to install skills in Antigravity, Claude Code and Codex
- Find skills in Antigravity
- Antigravity design and UI skills, compared
- Browse all skills
Sources
- alloyhtml.com and the docs, checked November 19, 2026
- alloyhtml/css on GitHub: README, LICENSE,
ai/alloy-css/SKILL.md,bin/cli.mjs - alloyhtml.com/llms.txt
- @alloyhtml/css on npm
- Show HN: Alloy CSS