Semantic CSS home Semantic

CSS for the modern web

Semantic CSS — Supercharge HTML

A drop-in, beautiful, hand-crafted stylesheet for semantic HTML under 10kB (3.4kB gz'd).

Download Documentation

One stylesheet · Native controls · Light & dark

Made with SemanticOn track

Your next good idea.

A few familiar elements, ready to use.

A good place to start.

Useful defaults for the things you build every day.

Start with HTML

Headings, links, forms, and tables get their styles from the elements you already use. Add classes for cards, tags, and a few useful variations.

Explore the typography →

Keep it simple

Include one CSS file. Use native controls, dialogs, and details elements without a component library or a JavaScript runtime.

Browse the components →

Make it yours

Choose a primary color and let the shared palette handle the rest. Built-in themes adapt to light and dark preferences.

Meet the themes →

A page with a heading, a short form, and a table is enough to see how the defaults work together and where your project needs its own styles.

One file. A fresh start.

Download the stylesheet, add it to your page, and write your HTML.

<link rel="stylesheet" href="https://semantic.win/semantic.css?v=ab73db1c8145">

You can keep building with the tools you already use. The examples on this site use the same stylesheet you download here.

Put the link in your document's <head> so the browser can discover the stylesheet as it reads the page.

Blue Green Violet Red Orange

Customize your theme

Add it to an existing site

Pick one page that already has a form or a table and add Semantic CSS there first. Load your existing stylesheet after it, and compare the page on a narrow screen and with keyboard navigation. Check that table headers still line up with their columns, form labels are easy to match to their fields, and focus is visible as you tab through the page.

Keep your layout and any styles specific to your project. Once you’ve seen which defaults work for that page, you can remove any local rules they already cover and try the same setup on another page.

Why Semantic CSS?

Semantic CSS helps you supercharge HTML with a single lightweight stylesheet. Start with the elements that already describe your page. A <label> names a form field, a <button> provides keyboard interaction, and <details> with <summary> gives you a disclosure the browser can open and close on its own.

The stylesheet gives those elements consistent defaults for spacing, type, and color. You can keep the markup small, skip extra wrappers and classes for everyday elements, and save JavaScript for behavior specific to your site.

A small data table is a good example. Its <caption> tells readers what the table contains, and its <th> cells mark the headers. That same markup gives the stylesheet elements it can style directly and gives assistive technology information about the table’s structure.

See what plain HTML can do

Try the release preview

Review a draft release and see how Semantic CSS styles its status and notes.

Release preview

Draft In review

What's new

The release includes updated form styles and examples.

Before publishing

Preview the release on a narrow screen.

See the component documentation for modals.

The TCP initial congestion window

On a new TCP connection, the initial congestion window limits how much data the sender can have in flight before it receives acknowledgments. With a window of ten segments carrying 1,460 bytes each, the first burst can carry up to 14,600 bytes of TCP payload. After HTTP and TLS overhead, the compressed HTML has a little less room. That’s where the roughly 14 kB rule of thumb comes from.1

If your HTML and the styles needed for the first render fit in that first burst, the browser can receive them without waiting for another round trip for the rest of the response. That matters most on high-latency connections. Keep the opening content and critical CSS small, and let the rest load as needed.

To see how much your page sends, reload it with caching disabled in your browser’s Network panel. Look at the transferred size of the document, then check which styles, fonts, and images the browser needs before it can display the main content.

What fits in the first response?

Measured from a local production build of this homepage with gzip -n -9, the HTML response body is about 10.3 kB. It includes the stylesheet, the interactive example, and the SVG previews in the gallery. The logo is a separate 0.6 kB SVG file before compression. The page also declares a 5.1 kB Apple touch icon that supported clients can request. The standalone stylesheet is 3.4 kB gzipped and is fetched separately when you click Download.

These figures measure the files. The first TCP window also has to carry response headers and TLS overhead. Keeping the styles and the first piece of content in the HTML puts them in the same response, where the browser can start using them as they arrive.

Small stylesheet. Plenty of possibilities.

A project workspace, a financial dashboard, a journal, and a control room. Four visual examples built from the same elements.

Compare how each example gives the same elements a different job. The workspace uses forms to organize tasks, the journal gives long-form text room to breathe, and the dashboards put figures and status updates up front.

Spring releaseTO DOIN PROGRESSDONEResearchWireframesDesign systemKickoff

Orbit

Bring projects, people, and the next good idea into one calm workspace.

Productivity app · Violet theme

TOTAL BALANCE$24,860+12.8% this monthJANMARJUN

Ledger

A clear view of cash flow, everyday spending, and the goals that matter to you.

Finance dashboard · Green theme

ISSUE 08 / SLOW LIVINGMake roomfor less.Read the story →

Margin

Notes on design, places, and the small rituals that make everyday life more interesting.

Editorial blog · Orange theme

All systems operationalUPTIME99.98%LATENCY42 msREGIONS6 healthyRequest volume · last 24 hours

Beacon

Service health, recent activity, and the controls your team needs, in one place.

Control panel · Blue theme

Ready to try it on your own page? Read the Semantic CSS documentation.