# latex-css: a classless stylesheet that makes plain HTML read like a LaTeX document

> LaTeX.css styles unstyled HTML into a LaTeX-looking page with almost no class names. It suits documentation, papers and personal sites; it is the wrong tool for application UIs and for anyone who needs more than the two languages the repo ships label files for.

**vincentdoerig/latex-css** — LaTeX.css is a CSS library that makes your website look like a LaTeX document

- Repository: https://github.com/vincentdoerig/latex-css
- Website: https://latex.vercel.app
- Stars: 3,481 · Forks: 150
- Language: HTML
- License: MIT
- Published: 2026-09-23 · Updated: 2026-09-23 · Language: en
- Canonical page: https://hysenlabs.com/projects/vincentdoerig-latex-css

## What latex-css is for, and who ends up using it

The README describes latex-css as "a minimal, almost class-less CSS library which makes any website look like a LaTeX document". The word that matters is class-less. You do not annotate your markup with a component vocabulary; you write ordinary HTML and the stylesheet decides how headings, paragraphs, lists, tables and blockquotes look. The project's own landing page is built this way.

That makes it a fit for a narrow but real set of pages: a paper or preprint published as HTML, class notes, a README rendered to a site, a personal page that should read like a printed document rather than a product page. The topics on the repository (classless, classless-theme, css-library) confirm the intent. It is not a component library and it does not pretend to be one.

The second group of users is less obvious: people who already write in a document tool and want the output to look familiar. The related searches around Tufte CSS and Terminal CSS suggest the same audience, people comparing classless themes rather than picking a framework. If you are choosing between those, the decision is mostly about which printed tradition you want the page to evoke.

## How a classless stylesheet actually takes over your page

The mechanism is plain CSS applied to element selectors. There is no JavaScript runtime, no hydration, no configuration object. The repository layout shows the shape of it: style.css at the top level, a fonts/ directory, a lang/ directory holding per-language label files, and a vite.config.js used to produce the minified build. The package.json declares "main": "./style.min.css" and ships dist, fonts, lang, style.css and style.min.css in the published files list.

Because the selectors target elements rather than classes, the cascade does the work. A paragraph is a paragraph. A blockquote looks like a LaTeX quotation. The optional class names exist only for constructs that HTML has no element for: the README mentions "author subtitle, abstract, lemmas, theorems, etc." and points to the class-based elements section of the site for the full list. You add those classes when you need a theorem environment, and ignore them otherwise.

One dependency is worth noting. The fonts/ directory is part of the published package, so the typeface is not left to whatever the browser picks. That is what makes the LaTeX resemblance hold across machines, and it is also why the package is larger than a stylesheet that inherits system fonts.

## Installing latex-css and styling a first page

The fastest path needs no package manager. The README gives this snippet for the head of your document:

```html
<link rel="stylesheet" href="https://latex.vercel.app/style.min.css" />
```

Point a browser at the file and you should see the LaTeX typography applied to whatever HTML is already there. The README offers a CDN alternative through Unpkg if you would rather not depend on the project's own host:

```html
<link rel="stylesheet" href="https://unpkg.com/latex.css/style.min.css" />
```

If your project already has a build, install it from npm instead. The README lists both commands:

```bash
npm install latex.css
```

```bash
yarn add latex.css
```

After installing, import or link the file the package exposes. The package.json sets main to ./style.min.css, so that is the entry point a bundler will resolve. For a non-English document, add the matching language stylesheet alongside the main one and set the html lang attribute. The README uses Spanish as the example:

```html
<link rel="stylesheet" href="https://latex.vercel.app/lang/es.css" />
```

```html
<html lang="es">
```

The README states that this changes the labels of theorems, definitions, lemmas and proofs, and directs you to the language support page for the list of supported languages and a demo. If your language is not in lang/, the labels stay in the default language.

## Where latex-css stops being the right choice

A classless stylesheet cannot know your layout intent, so it imposes a document one. Long-form prose benefits; a settings page, a data table with many columns, or a landing page with a hero section does not. You can override anything with your own CSS, but at that point you are fighting the library rather than using it, and the value of the classless approach disappears.

The language support is the second constraint. The README documents a lang/ directory and shows es.css, and it points to a language support page for the full set. It does not claim coverage of every language. If you publish in a language without a label file, the theorem and proof labels will not match your text, and nothing in the package will warn you.

The third limitation is the one that applies to any CSS library without a version contract: the published files include style.css and style.min.css, and a new release can change how an element renders. The releases list shows v1.14.0, v1.13.0 and v1.12.0, roughly one a year. If you link the hosted style.min.css directly, you take whatever is on the server at request time. Pinning to a version through npm, or vendoring the file, is the only way to keep the rendering you reviewed.

## latex-css compared with a utility framework and with Tufte CSS

The obvious alternative is a utility-first framework such as Tailwind. The difference is not cosmetic. With Tailwind you compose the appearance in the markup, class by class, and the stylesheet contains only the utilities you referenced. With latex-css you write no classes at all and the appearance is decided for you. Tailwind gives control and costs markup noise; latex-css gives a finished document look and costs the ability to deviate without writing overrides.

Tufte CSS is the closer comparison, and the README is explicit that "the idea of sidenotes was taken and adapted from Tufte CSS". Both aim at a printed-page feel. They differ in tradition: Tufte CSS follows Edward Tufte's book layout, with a wide margin used for sidenotes, while latex-css follows LaTeX's article conventions, including theorem and proof environments that Tufte CSS has no equivalent for. If your content is a paper with numbered results, latex-css covers more of it out of the box. If it is an essay with marginal annotations, Tufte CSS starts closer to the target.

A third point of comparison sits outside CSS entirely. People searching for a way to make Typst look like LaTeX are solving the same aesthetic problem in a typesetting tool rather than in the browser. latex-css is the browser answer: you keep HTML and get the look, without a typesetting toolchain.

## Maintenance, versioning and the MIT licence

The repository is not archived, and the last push was on 2026-05-13, the same date as the v1.14.0 release. The release cadence visible in the list is about one minor version per year: v1.12.0 in September 2024, v1.13.0 in May 2025, v1.14.0 in May 2026. That is a slow, stable rhythm, and it fits a stylesheet whose surface is small. It also means a fix you need may wait months.

Upgrade cost is low in the common case. There is no runtime, no API and no build integration beyond resolving the main entry, so moving from one minor version to the next is a matter of replacing a file or bumping a dependency. The risk is visual rather than functional: a change to an element selector can shift spacing or type size across every page at once. The repository ships a CHANGELOG.md, so that file is where to look before bumping. The repository also includes elements.html, an HTML5 markup test page, which is the practical way to see how a new version renders the elements you rely on.

The licence is MIT, stated in the README, in package.json and in the LICENSE file. For most users that means the usual permissive terms: keep the copyright notice, and you can use it in closed products. The README also credits David Zollikofer's latexCSS as the project latex-css is based on, Andy Bell's Modern CSS Reset for most of the reset, and cbracco's html5-test-page for the markup test page. If you redistribute the library, those attributions are part of what you inherit. This is a description of what the repository states, not legal advice; check the LICENSE file yourself.

## Conclusion

Adopt latex-css if you write long-form HTML, Markdown output or a static site and want a LaTeX-like page without a build step or a class taxonomy; the link tag plus style.min.css is the whole setup. Do not adopt it for dashboards, marketing pages or anything where the layout must differ from a document column. Before committing, open https://latex.vercel.app/elements to check the HTML5 elements you actually use, confirm your language has a file under lang/ (es.css exists; the README points to the language support page for the rest), and check CHANGELOG.md for what v1.14.0 changed relative to the version you are on.

## FAQ

### Does latex-css require any JavaScript or a build step?

No. The README's first installation option is a single link tag pointing at style.min.css, and the package contains CSS, fonts and language files rather than scripts. A build is only involved if you install it through npm and let a bundler resolve the main entry.

### Can I use latex-css for a language other than English?

The README documents a lang/ directory and shows es.css being added alongside the main stylesheet with the html lang attribute set to es. It says this changes the labels of theorems, definitions, lemmas and proofs, and points to the language support page for the list of supported languages.

### What do I have to add to my HTML to use latex-css?

Usually nothing beyond the stylesheet link, because the library is almost class-less and styles elements directly. The README notes that optional class names exist for elements with special styles such as author subtitle, abstract, lemmas and theorems, and links to the class-based elements list.

### Under what licence is latex-css released?

The README, package.json and the LICENSE file all state the MIT licence. The README also credits the projects it builds on, including David Zollikofer's latexCSS and Andy Bell's Modern CSS Reset.

## Sources

- [License: MIT](https://github.com/vincentdoerig/latex-css/blob/master/LICENSE)
- [Project website](https://latex.vercel.app)
- [README](https://github.com/vincentdoerig/latex-css/blob/master/README.md)
- [Releases](https://github.com/vincentdoerig/latex-css/releases)
- [vincentdoerig/latex-css on GitHub](https://github.com/vincentdoerig/latex-css)

---

Hysen Labs editorial analysis, written from the project's own repository and release notes. Cite the canonical page: https://hysenlabs.com/projects/vincentdoerig-latex-css
