Why do you need to create a child theme?
If you want to make any changes to your WordPress theme you will need to create a child theme first, otherwise, you will lose your changes with the next theme update, so all your hard work will be lost.
If you just want to make changes to your CSS, there is an easier way and you won’t need a child theme for that, just go to Appearance – Customise – Additional CSS (Video: 9min 15sec).
However, any other file changes will need to be done in a child theme.
As always it’s really important that you take a full back up of your site (your files and databank) before making any changes on your site, just in case something goes wrong then you can restore the last version of your website with ease.
This is the code for the function.php, please copy and paste this into the function.php in your child theme.
The code might not be displayed on a mobile device, please open the page on a laptop or desktop computer to copy the code over, or go to
I hope you found this post helpful to learn how to create a child theme in WordPress.
Please let me know in a comment below what you think, we love comments! I’m sure you’ll leave a lovely or constructive comment, but please feel free to read this about nasty comments, if you’re interested why some people leave hate comments and what you can do if that happens to you.
If you’re interested in learning more about WordPress and how to start with niche blogging or build your own small business website with lots of helpful step-by-step WordPress tutorials on keyword research and how to deal with website maintenance please check out our Index on ‘How to start a blog 2021‘ for a full list of tutorials.