A child theme is a WordPress theme that is created based on your parent theme. If you have made any changes to the parent theme, then it is not safe, so it is important to know how to create a child theme in WordPress
It has become very important to use a child theme in 2025 because at this time a lot of updates are coming in the theme, such as there may be a reason to update the theme for a new feature or security update. If you have customized something in the parent theme,
then everything will be deleted after the theme is updated. So first find out How To Create Child Theme in WordPress 2025 Guide After that, if you create a child theme and customize it in such a child theme, then even after the update, it remains safe and is not deleted, so child theme is important.
In this article we will know. What is a child theme, how does it work, how to create a child theme and what best practices you should follow
Table of Contents
1. What Is A Child Theme In WordPress
1.1 What is a child theme? Let’s know in a simple way
Child theme is a theme that is based on any parent theme. It inherits the design, features and functionality of the parent theme, i.e. it works to use the features of your parent theme. Therefore, you can change anything without touching the parent theme with the help of child theme.
A parent theme is the theme you install. A child theme is a separate theme that depends on the parent theme. You can customize the CSS layout or functions of the child theme using it. Even if the parent theme is updated, changes made to the child theme are preserved.
1.2 What Is A Parent Theme
What is a parent theme? For example, the theme you have installed and activated on your website is called a parent theme. Suppose you have activated GeneratePress theme on your website, then this is your parent theme and child themes are created from this.

1.3 Why Use A Child Theme
Suppose you have installed a theme named Astra. This is your parent theme. Now you want to change the background from black to white or change the font. You can make changes directly in the Astra theme but
when any update of the Astra theme comes, all your changes will be deleted. If you had created a child theme and made changes to it, then any update of Astra will not affect your changes.Child themes should be used so that your custom changes are not deleted even after the update,
so this should be done to keep your theme safe. And there are many advantages of using child themes, such as you can also duplicate a page or post by customizing something in the child theme. This is a safe and clean way to customize the theme without plugins, it also makes maintenance and debugging easier.
2. Tools And Requirements (2025 Edition)
2.1 What You Need Before You Start
To create a WordPress child theme, you need a few things like a WordPress dashboard, a hosting file manager, and a code editor like Notepad.
Note: You can do it with any hosting, I use Hostinger, so I will teach you Hostinger, the process is same, you just have to follow it carefully, it works in all
3. How to Create Child Theme in WordPress 2025
You can create a child theme of any theme. You can also create a child theme of any theme you use. Currently I am using GeneratePress theme, so I will teach you how to create child theme in wordpress 2025 of GeneratePress. The process is also the same, you just have to follow the steps carefully. Let’s start.

4. How to Create a Generatepress Child Theme
4.1 Steps: Create a Child Theme Folder
First of all you have to go to Hostinger’s cpanel, you can do this with any hosting, after that you have to go to domain by clicking on the website and you have to choose your domain, select the domain on which you want to create a child theme, next to it you will see the admin panel and dashboard, you have to click on dashboard

Steps 1. click on file manager your Hostinger

Steps 2. public server will open, double click on public html,

Steps 3. You have to select your website and double click on it, If you have created a website on a subdomain then all the subdomains will appear here. You have to carefully choose the website on which you want to create a child theme.

Steps 4. then you have to double click on wp-content

Steps 5. Now you have to double click on themes,

now you will see all the themes that you have installed, keep in mind that the child theme will be of the one you have activated, I have kept generatepress theme activated, I am going to make generatepress theme a child theme right now

Note: Now you have to create a folder here, remember to name it generatepress-child, the spelling should not be wrong otherwise it will not be possible, so look carefully and follow
Now to create a folder, look at the top left and you will see an option called New Folder. You have to click on it.

Now you should be very careful here and if you want to create a child theme of any theme then put the original name of that parent theme here and add -child behind it. You can also see in the image given below.

4.2 Steps: Create 2 file style.css and functions.php
Now you have to create 2 files inside this child theme folder, one file will be named style.css and the other file will be named function.php. Keep in mind that the name of the file should not be wrong and the spelling should be correct. Let’s create this as well.
Now you have to go inside the child theme folder or if you have already gone inside the child theme then look on the left side, you will see an option new file, click on it
Now you have to write style.css in this box. Remember I am saying again and again that the spelling should not be wrong. Copy what I have written and paste it in the file box and click on create.

As soon as you click on create, a text code editor opens in front of you, here you have to paste a code, you will find the code below, just copy it and paste it here and then you have to do 2 things, put the name of the child theme in theme name like Generatepress-child and put the name of your parent theme in template like Generatepress now save it and come back.
1. This is the code of : style.css
/*
Theme Name: My Child Theme
Theme URI: https://example.com/my-child-theme/
Description: A child theme of the parent theme
Author: Your Name
Author URI: https://example.com/
Template: parent-theme
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
*/
2. This is the code of : functions.php
<?php
add_action( 'wp_enqueue_scripts', 'my_child_theme_enqueue_styles' );
function my_child_theme_enqueue_styles() {
wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' );
wp_enqueue_style( 'child-style', get_stylesheet_directory_uri() . '/style.css', array(
'parent-style' ) );
}


Now create another file like this, just change its name. Its name will be functions.php. Create a file with this name and then the text code editor screen will open. Copy the code and paste it in it as well. You don’t need to change anything in it. Leave it as it is. save same process and go back


4.3 Steps: How to add image in child theme
Now you have to do one thing, you have to add an image for the theme, background image as you can see in the image below, you can add any image, it can be any image, you have to add it as per your choice, let’s learn how to add it

First of all you have to select the image according to your choice, then look carefully, whatever image you want to use for child theme, first change the name of that image like you have to click on rename and just write screenshot and save it, only then your image will work

Now you have to upload the image by clicking on upload. You will see the upload option on the top right. Click on it. Then you will see 2 options.
File and Folder. You have to click on the file and then select the image and upload it.

Once the image is uploaded, the image will automatically appear between the two files. When you go to the WordPress dashboard

5. How to Activate Child Theme
To activate the child theme, first you have to go to the WordPress dashboard, after that you have to click on Appearance, then you have to click on Theme, after that you will see the child theme here, activate the one you have just created by clicking on Activate, now your child theme is ready

6. How to Customize Your Child Theme
Now your child theme is ready, now you can make any changes in it and save it, after any update the changes made by you will be safe, nothing of yours will be deleted, so whenever you have to make some changes in the theme, then definitely use the child theme.
If you want to customize child theme then follow these steps
- Write your custom CSS in style.css file
- Copy parent theme’s template like header.php and footer.php and edit it in child theme
- Add new functions in function.php
- Customize design settings using theme.json for block theme
7. Common Mistakes to Avoid
- ❌ Typing the template name wrong
- ❌ Forgetting to enqueue the parent style
- ❌ Accidentally editing the parent theme
- ❌ Mistyping the file name (e.g. functions.php instead of function.php)
- ❌ Pasting the code in the wrong place
- Note: Remember one thing, always make a backup before making any changes
8. How to Create Child Theme in WordPress Using plugin
If you use a plugin then you do not need to paste the code yourself because your plugin does this work itself and gives us a child theme. We just have to install and activate the plugin and by following some steps we can create a child theme of any theme in 1 click, so let’s start.
So first of all you have to install a plugin named child theme configurator. Although there are many plugins available but this is the most popular and easy too, so I use it. After installing the plugin, activate it.

Now you have to do some settings of the plugin like first of all you have to keep the mouse on the tools, inside that you will see the option of child theme, click on it

Now you have to follow some steps, look carefully and follow them, some images are given below, if you don’t understand anything here then you can see the image given below, first of all you have to click on it create a new child theme, and scroll down a bit

Now you have to select the theme, select the theme of which you want to create a child theme and click on Analyze

Now you have to go to the end, there you will see an option named Create New Child Theme, click on it

Now you have to activate the child theme. How to activate it? You have to go to Appearance, go to Theme and just below or on the right side of your parent theme you will see the child theme, we had made Generatepress a child theme, now it is named Generatepress-child, activate it.

Now your child theme is ready. Now you can change anything in the child theme without touching the parent theme.
9. Final Tips
- Always test on a staging site
- Always keep your parent theme updated
- Use version control for larger customizations
- Don’t forget to check your site after every change
10. Conclusion
Creating a child theme may seem a bit difficult at first, but believe me, if you learn it once, the same difficult task starts to seem easy to you. If you liked our guide, do not forget to comment and share it with friends. Best wishes from our side for your further journey.
2 thoughts on “How To Create Child Theme in WordPress 2025 Guide”