A WordPress child theme inherits the style and functionality of a parent theme while keeping all your modifications separate. The big payoff: you can update the parent theme without losing any of your customizations.
In this tutorial we’ll show you two ways to create a child theme — manually with code, and with a plugin. (If you’d rather customize with code snippets instead of a whole theme, see our guide to adding custom CSS and JavaScript.)

Method 1: Create a child theme manually
It only takes a few minutes. This example uses the default WordPress theme Twenty Twenty-One as the parent, but the process is the same for any theme.
Step 1: Create the child theme folder
Create a new folder inside wp-content/themes/ in your WordPress installation. This folder will hold all your child theme’s files. You can name it anything — for this demo, we’ll use getstartedwp-child.

Step 2: Create the child theme files
style.css — Create this file in your new folder and paste the following, adjusting the details to match your theme:
/*
Theme Name: GetStartedWP Child Theme
Theme URI: https://getstartedwp.com/
Description: GetStartedWP Child Theme.
Author: GetStartedWP
Author URI: https://getstartedwp.com/
Template: twentytwentyone
Version: 1.0
*/
The critical line is Template: twentytwentyone — it must match the parent theme’s folder name exactly. That’s what tells WordPress this is a child theme and which parent it belongs to.
functions.php — Create a second file that loads the parent theme’s stylesheets:
<?php
if ( ! defined( 'ABSPATH' ) ) exit;
/* Enqueue parent theme styles */
function gswp_child_theme_styles() {
wp_enqueue_style(
'child-style',
get_stylesheet_uri(),
array( 'twenty-twenty-one-style' ),
wp_get_theme()->get( 'Version' )
);
}
add_action( 'wp_enqueue_scripts', 'gswp_child_theme_styles' );
If your parent theme is different, replace twenty-twenty-one-style with that theme’s stylesheet handle.
Don’t use
@importin style.css to load the parent stylesheet — it’s slower and can cause the parent styles to load twice. Enqueueing, as shown above, is the correct method.
screenshot.png (optional) — a 1200×900px image shown as the theme’s preview in Appearance → Themes.
Step 3: Activate the child theme
Go to Appearance → Themes and you’ll see your child theme listed. Click Activate. Your site should look identical to before — now any CSS or template changes you make go into the child theme, safe from parent updates.
Method 2: Create a child theme with a plugin
If you’d rather not touch code, Child Theme Configurator (300,000+ active installs, regularly updated) does it all through a settings page.
- Install and activate Child Theme Configurator from Plugins → Add New.
- Go to Tools → Child Themes (in newer versions it may appear under the Themes menu).
- Select the Parent/Child tab, choose your parent theme, and click Analyze to verify it can be used as a parent.
- Name your child theme, review the default settings, and optionally copy the parent’s menus, widgets, and Customizer settings so nothing is lost in the switch.
- Click Create New Child Theme, preview it to confirm everything looks right, then Activate & Publish.








What to customize first
With your child theme active, the typical first customizations are:
- CSS tweaks in the child theme’s
style.css(fonts, colors, spacing). - Template overrides — copy a template file (like
header.php) from the parent into the child theme folder and edit the copy. WordPress will use your version automatically. - Custom functions in the child theme’s
functions.php.
Want to go deeper into WordPress code? Our basic plugin development tutorial shows how to package custom functionality as a plugin instead.
Thanks for that awesome tutorial, it helped me a lot.
Nice tutorial, good explained. Where can I find more lessons or examples?