Sign inBlogSupportContact
Tools

Add custom CSS to WordPress without a plugin or child theme

Hide an element, tweak a color, fix a margin. Ship a CSS snippet in 30 seconds. No Customizer, no child theme, no extra plugin.

4 min read May 2026 create custom css

You need five lines of CSS. Every option feels heavy.

Your theme's submit button is the wrong shade of green. You want it darker. That's ten characters of CSS. But to ship ten characters of CSS on a WordPress site, you're supposed to: create a child theme, enqueue a stylesheet, or install a plugin dedicated to letting you type CSS into a textarea.

Each approach is heavier than the problem. Child themes are long-term infrastructure for a one-line tweak. The Customizer's Additional CSS is tied to the theme — switch themes and you lose everything. Dedicated CSS plugins are yet another plugin to maintain.

What most people do instead

Customizer → Additional CSSTied to the active theme. Switch themes and every tweak disappears. No way to organize multiple snippets.
Install Simple Custom CSS (or similar)Yet another plugin, maintained by someone else. Auto-update breaks your site eventually.
Create a child themeFull theme folder, style.css, functions.php, enqueue logic. Serious overkill for a color tweak.

A better way: one command, one snippet

Open the TrueCommander navigator. Type create custom css. Paste your CSS. Save it. The snippet outputs as a <style> block on every page load, registered automatically as a startup command.

TrueCommander
Custom CSS registered
Output on every page load
Name: dark green button
Size: 38 characters1 rule

Each snippet is independent. Create ten separate snippets, each named ("header fixes", "mobile tweaks", "print styles"). Disable one via Startup Commands to remove its <style> block. No massive textarea to scroll through — snippets stay organized.

How it works

The command auto-registers itself as a startup command with your CSS as the payload. On every page load, WordPress outputs a <style> block containing your code. The code is output raw — you're responsible for its correctness, so test locally first.

1
Run the command with your CSSGive it a name ("header tweaks") and paste the CSS in the -code parameter
2
Auto-registered as a startup commandEach registered snippet adds one <style> block. Independent, named, toggleable.
3
Disable or delete from Startup CommandsFlip the toggle to disable. Delete the entry to remove the snippet entirely.
ParameterValue
-nameDisplay name for the snippet (e.g., "dark green button")
-codeRaw CSS. Output verbatim inside <style> tags.
ModelAccumulate — each run adds one independent style block
ScopeFrontend pages only (admin CSS unaffected)
Can be used in

Real example

Your WooCommerce cart page shows an empty-cart message you want to redesign. The theme's developer made it hard to override. Opening the Customizer Additional CSS means tying the fix to this theme forever.

Instead, you run create custom css with a name "cart empty message" and your 12 lines of CSS. The snippet now outputs on every page load. Switch themes next year? The snippet follows you — it's theme-agnostic, stored in the database, managed from the Startup Commands page.

A client asks you to add a holiday banner background in December. Run the command again with a different name — "holiday banner" — and 20 lines of CSS. Two independent snippets. When the holidays end, toggle the second one off from Startup Commands. The banner is gone. The first snippet is untouched.

Goes further with TrueCommander

Ready?

Ship CSS in 30 seconds. Zero ceremony.

This is one of 91 commands. All included with every license.

Cookies. The short version.

Essential cookies keep the cart and theme working. Analytics only fire if you say yes. Read our policy.