Skip to content

Themes

Themes are files stored in the themes/ subdirectory of the upload path, or at the root as a fallback. Their name must start by theme- to be recognized.

theme-<name> plain file (CSS or JSON bundle)
theme-<name>.json JSON bundle — explicit extension, also accepted
theme-<name>.gz gzip-compressed plain file
theme-<name>.json.gz gzip-compressed JSON bundle

Important: the <name> part must not contain dots. The only accepted extensions are .json (for an explicit JSON bundle) and .gz (for compression). Any other extension will cause the file to be ignored by the scanner.

Valid: theme-dark, theme-dark.json, theme-dark.gz, theme-dark.json.gz Invalid: theme-dark.css, theme-dark.v2, theme-dark.tar.gz

A plain CSS file. Still fully supported. Applied directly as a <style> override on top of the built-in stylesheet.

body, html {
background-color: #222;
color: #eee;
}

A JSON file containing all assets. Detected automatically when the file parses as valid JSON.

{
"manifest": {
"name": "Dark Blue",
"version": "1.0.0",
"owner": "ESP3D",
"github": "https://github.com/luc-github/ESP3D-WEBUI",
"description": "Dark theme with custom font and controls overrides.",
"supportedVersion": "3.*",
"targetSystem": "*"
},
"variables": {
"--accent": "#e8622a",
"--accent-hover": "#c04d1e"
},
"css": "body, html { background-color: #222; color: #eee; } .btn.btn-primary { background: var(--accent) !important; }",
"fonts": [
{
"family": "MyFont",
"data": "<base64-encoded font file>",
"format": "woff2",
"weight": "400",
"style": "normal",
"display": "swap"
}
],
"scripts": ["https://cdn.jsdelivr.net/npm/animejs@3/lib/anime.min.js"],
"js": "console.log('theme loaded');"
}

All fields are optional. Injection order: variablescssfontsscripts (sequential) → js.

Metadata and compatibility constraints. If absent, the theme is always accepted.

FieldRequiredDescription
namenoDisplay name
versionnoTheme version (semver)
ownernoAuthor / maintainer
githubnoRepository or homepage URL
descriptionnoShort description
supportedVersionnoWebUI version pattern (e.g. 3.*, 3.1.*). If absent → accepted on any version
targetSystemnoComma-separated targets (e.g. *, 3d printer, cnc, sand table). If absent → accepted on any target

CSS custom properties injected on :root before the CSS, as <style id="themevariables">. Keys must start with --.

"variables": {
"--accent": "#e8622a",
"--accent-hover": "#c04d1e",
"--font-size-base": "14px"
}

CSS content injected as <style id="themestyle"> after variables. Overrides the built-in stylesheet. Use !important where needed.

Custom fonts injected as @font-face rules in <style id="themefonts">.

Each font object supports three source formats:

FieldDescription
dataBase64-encoded font bytes (offline, self-contained)
srcURL of the font file (online systems, lighter bundle)
sourcesArray of { src, format } or { data, format } objects for multi-format fallback

Common fields: family, format (default woff2), weight (default 400), style (default normal), display (default auto).

External JavaScript URLs loaded sequentially before the inline js field.

JavaScript injected as <script id="themescript"> after all scripts have loaded. Runs in the main document context.

Important: Theme JS runs outside the Preact virtual DOM. Do not remove nodes that Preact owns — use display: none instead. Use a MutationObserver if you need to react to DOM changes.

When an extension iframe loads, the WebUI automatically injects the full theme (variables, style, fonts, scripts, js) into it. Extensions receive the full theme without any extra configuration.

Starting with WebUI 3.1, the WebUI can scan for themes in /themes (or root / as fallback). The scan filters themes by supportedVersion and targetSystem if present in the manifest. Themes without a manifest are always accepted.

Upload the theme file using the flash file system panel in dashboard. image

Select theme in interface settings image image

Once changes are applied, WebUI will automatically restart

image

More themes are available in the themes showcase.

ThemeFormatDownload
DarkLegacy CSS (gzipped)theme-dark.gz
MNJLegacy CSStheme-mnj
OrcaLegacy CSS (gzipped)theme-orca.gz
PurpleLegacy CSStheme-purple

See also the Orca theme showcase page for more details.