Every WordPress owner who has lost a weekend of CSS work to a theme update has learned the hard way why child themes exist. A child theme is a small, separate theme that sits on top of your active theme, inherits everything from it, and keeps your customisations safe when the parent theme updates. This guide walks through what a child theme is, why it matters, how to create one using the Plesk File Manager on smartxhosting.uk (no FTP, no command line), what you can customise inside it, and the cases where you do not actually need one.
What a child theme is · Why child themes matter · How a child theme works · Creating a child theme step by step · What you can customise in a child theme · Alternative: using a child theme plugin · When you do not need a child theme · Testing on staging first · Ongoing maintenance of a child theme · Frequently asked questions
A WordPress child theme is a separate theme that sits alongside your main (parent) theme and inherits all of its design, layout and functionality. Your customisations — CSS tweaks, template overrides, additional PHP functions — live inside the child theme. WordPress loads the child theme first, falls back to the parent for anything the child does not override.
The key property: when the parent theme updates, WordPress replaces the parent's files. Your child theme folder is untouched. Every customisation you made survives.
Without a child theme, editing your active theme directly is a ticking time bomb:
style.css.single.php, to change post layout.functions.php.Skipping theme updates to preserve your work is not an option — updates patch security vulnerabilities, fix bugs, maintain WordPress compatibility. A child theme resolves the dilemma: update the parent freely, keep your modifications safe.
If you have ever lost custom work to an update, this is the one thing to set up on every WordPress site.
A child theme is a folder inside wp-content/themes/ with (at minimum) two files:
When WordPress sees an active child theme, it loads the parent first, then the child on top. Any file in the child with the same name as a file in the parent takes priority. If you copy single.php from the parent to the child and modify it, WordPress uses your version.
Key principle: the child inherits everything. You only add the files that differ. A child theme with nothing but style.css and functions.php looks identical to the parent — until you start adding customisations.
This walk-through uses the Plesk File Manager available on all smartxhosting.uk WordPress plans. No FTP client, no command line needed.
Log in to Plesk. Click Files. Navigate to httpdocs > wp-content > themes. You will see a folder per installed theme — for example, twentytwentyfive for the Twenty Twenty-Five default.
Click New > Create Directory. Name it based on your parent theme with -child appended — e.g. twentytwentyfive-child. This naming convention makes the parent-child relationship obvious to anyone inheriting the site later.
Open the new folder. New > Create File, name it style.css. Edit the file and add:
/* Theme Name: My Child Theme Template: twentytwentyfive Description: Child theme for Twenty Twenty-Five Version: 1.0 Author: Your Name */ /* Add your custom CSS below this line */
The two critical lines:
twentytwentyfive.Save.
Still inside the child theme folder, create functions.php. Add:
<?php
// Enqueue parent theme stylesheet
function my_child_theme_enqueue_styles() {
wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' );
}
add_action( 'wp_enqueue_scripts', 'my_child_theme_enqueue_styles' );
This tells WordPress to load the parent's stylesheet so the site keeps its existing design. Without it, only the child's (empty) style.css loads and the site appears unstyled.
Save.
Go to Appearance > Themes in the WordPress dashboard. Your child theme appears alongside the parent. Click Activate. The site looks identical to before — the child has inherited everything. Now you can customise.
Three types of customisation.
Add CSS rules to the child's style.css, below the header comment. Rules here override the parent. Examples:
/* Change heading colour site-wide */
h1, h2 { color: #00695c; }
/* Increase button padding */
.wp-block-button__link { padding: 16px 32px; }
/* Hide a specific element */
.site-tagline { display: none; }
For a block theme on smartxhosting.uk, you often do not need a child theme at all for CSS — Appearance > Editor > Styles > Custom CSS saves CSS directly to the database, which is update-safe. See the when not to use a child theme section.
To modify a specific template — say single.php for single post layout, page.php for page layout, header.php, footer.php — copy the file from the parent to the child. Edit the copy. WordPress uses your version.
Never edit the file in the parent theme folder — those changes disappear on the next update.
Add new functions, action hooks or filter hooks to the child's functions.php. The child's functions.php does not override the parent's — both load. The child's loads first. This means you add new functionality without losing anything from the parent.
Example — add a shortcode for the current year:
function current_year_shortcode() {
return date( 'Y' );
}
add_shortcode( 'year', 'current_year_shortcode' );
// Use [year] in any post, page or widget.
Only add files you actually need to change. A child theme with dozens of copied template files becomes hard to maintain and may miss out on parent theme improvements because your copies are stale.
If you would rather avoid manual file editing, the Child Theme Configurator plugin creates child themes visually.
The plugin also includes a visual CSS editor for making style tweaks without opening files. Good option for non-technical owners who want child-theme safety without writing code.
Child themes are not always necessary. Cases where you can skip the extra layer:
Block themes store your design customisations (colours, typography, layout, template edits) in the WordPress database through the Full Site Editor, not in theme files. Parent theme updates do not overwrite them. For a block theme used in FSE-only mode, a child theme is redundant.
If your customisations are purely CSS, Appearance > Customise > Additional CSS (classic themes) or Appearance > Editor > Styles > Custom CSS (block themes) stores CSS in the database. Update-safe. Simpler than maintaining a child theme.
For small PHP additions (a custom shortcode, a helper function, a minor admin tweak), the free Code Snippets plugin runs your snippets from the database. Safe across theme updates. No child theme needed.
If you are only changing one colour and one font size, use the theme's built-in settings rather than building a whole child theme.
Before creating a child theme on a live production site, clone to staging through the Plesk WordPress Toolkit:
Staging lets you experiment without risk. A typo in functions.php can bring a site down — better to discover that on staging than production.
A child theme is not set-and-forget. Over time:
style.css noting what you have changed, when, and why. Essential if someone else maintains the site in future.What is the difference between a theme and a child theme?
A theme is a standalone design. A child theme is a theme that depends on a parent theme for its core design, and overrides only the parts you want to change. You cannot use a child theme without its parent being installed.
Do I need both style.css and functions.php?
Yes, at minimum. style.css declares the theme and its parent; functions.php enqueues the parent's stylesheet. Without functions.php, your site loads unstyled.
Will a child theme slow down my site?
Negligibly. The overhead of loading two stylesheets rather than one is milliseconds. Performance impact is effectively zero.
Can I create a child theme for any parent theme?
Almost always yes. A tiny number of themes are coded in ways that break child-theme expectations (wrongly absolute asset paths, for example). Test on staging if the parent is unusual.
What happens to my child theme if I change the parent theme?
The child theme becomes inactive because its Template line points to the old parent. You can either rename the child theme's Template line to the new parent (if compatible) or create a new child theme for the new parent.
Do block themes need child themes?
Usually not. Block theme customisations through the Full Site Editor are stored in the database and survive parent updates. Use a child theme only if you need PHP customisation or template override beyond what FSE provides.
Can I preview a child theme before activating?
Yes. Appearance > Themes, hover the child theme, click Live Preview. Shows your site with the child theme active without switching on production.
Why does my child theme look unstyled after activation?
You forgot the functions.php enqueue code. Double-check the file exists, contains the wp_enqueue_style call, and has no syntax errors.
Can I delete the parent theme once the child is active?
No. The child theme depends on the parent for all inherited files. Deleting the parent breaks the child. Keep the parent installed.
How do I remove a child theme?
Switch back to the parent theme in Appearance > Themes. Then delete the child theme folder from wp-content/themes/. Customisations are lost unless backed up.
Launch your WordPress site on smartxhosting.uk
UK hosting with the Plesk WordPress Toolkit, LiteSpeed Cache, Redis object caching, free Let’s Encrypt SSL, free CDN and daily backups — from £2/month.
View WordPress hosting plans →