Last Updated on
WordPress is one of the most popular, and effective, content management systems out there. You can set up a website within minutes, style it using the diverse themes and plugins offered to WordPress users, and not necessarily break the bank while you’re at it.
That being said, WordPress does come with its challenges. With the market being flooded with high quality themes, it is not surprising theme developers are competing against one another. So, developers constantly update their themes for tighter security, better web design, and increased functionality.
But wait, that’s a good thing right?
Of course it is! There is nothing better than having updated themes. In fact, updated themes ensure an appealing design and a great user experience. However, there is a drawback to this.
For instance, say you make custom changes to your website in order to make it truly unique. Or maybe you add some code to add a functionality your theme doesn’t offer. And then your theme automatically updates. All of that hard work you invested into your website is now gone.
The truth is WordPress does not always update well. And in response to this particular challenge came the concept of child themes.
Today we will look at what child themes are, why they are beneficial to website owners, and how you can create one easily. And when I say easily, I really mean it.
What is a Child Theme?
“A child theme is a theme that inherits the functionality and styling of another theme, called the parent theme.”
But that’s not all. They allow you to modify, or add to, the functionality of the parent theme without ever losing any of your changes when your theme updates.
How Does it Work?
The first thing you must do in order for a child theme to work is create one from an existing theme. This existing theme then becomes the ‘parent theme’.
Once activated on your website, just like you would activate any other WordPress theme, WordPress looks to that child theme’s files first. From these files WordPress displays your webpages according to the files that are present.
And, if any of the basic functionality or design files required to display your webpages properly are missing, WordPress then checks your parent theme’s files. From these files WordPress then grabs the needed files for your website to render correctly. Lastly, after putting all of it together like a puzzle, WordPress displays your website to site visitors.
Why Use One?
There are lots of reasons to use a child theme on your website. In fact, most serious website owners will tell you it is a must. Let’s check out why:
- Store custom changes. They act as a warehouse for custom changes made to your website. This way, when your parent theme updates, your child theme remains intact with all of those changes right where you left them.
- Speed up development time. Rather than start from scratch and build the perfect WordPress theme, use a solid theme that has already been developed that has most of the functionality you require. In this way your theme acts as a base for your website. Then create a child theme and build off of its parent theme to create exactly what you want.
- Learn theme development. This is a great way to learn the basics behind coding and developing functioning themes. Using the parent theme as a starting point, and the child theme as a practice place, you learn a lot.
- Play it safe. If you modify your website’s parent theme files, and make a coding error, you can break you entire site. If you make a coding error on your child theme, your parent theme is unaffected. Simply start over with a clean slate and make it right.
- Stay secure. Use one for making changes so that your parent theme can stay updated at all times. This allows for bugs to be fixed and security issues to be addressed so your website stays safe.
In the end, there really is no reason not to use child themes. The benefits far outweigh the seemingly nonexistent negatives. Plus, they are easy to create.
How to Create a Child Theme…the Easy Way
There is a good chance you may be aware of the more difficult, manual way of creating child themes. If so, you know that this involves some basic technical skills such as modifying PHP files, uploading new files, and modifying the code.
If you are interested in learning this method, check out a guide I wrote a while back explaining the steps for doing so.
If however you are like me, and want to do things in the easiest way possible, keep reading. I am going to show you how to use a simple WordPress plugin called Child Theme Configurator to create a child theme for your website. In fact, I like this plugin so much, it is what I use on my personal website to create my own.
Step 1: Install and Activate Child Theme Configurator
First navigate to Plugins > Add New from your WordPress dashboard. Then search for Child Theme Configurator.
Select Install Now. Then click on Activate Plugin. Child Theme Configurator is now ready for use on your website.
Step 2: Create a Child Theme (Plugin Steps 1-3)
Navigate to Tools on your WordPress dashboard and notice in the dropdown menu a menu item labeled Child Themes.
Click on this to start the child theme creation process.
A screen will pop up that will let you do a number of things:
- Create a new child theme using an installed theme as a parent theme.
- Configure an existing child theme.
- Duplicate an existing child theme.
- Reset an existing child theme.
Select CREATE a new Child Theme.
Underneath the area labeled Select a Parent Theme choose from the dropdown menu the existing theme installed on your website that you want to create a child theme out of. Note that this plugin also gives you the option of saving a backup of the selected parent theme.
Next click on Analyze to check for stylesheet dependencies and potential problems.
When your parent theme is given the okay to be used for creating a child theme, continue to the next steps.
Step 3: Create a Child Theme (Steps 4-9)
Child Theme Configurator’s steps 4 through 9 deal with configuration settings.
- Name the new theme directory. This is automatically determined for you. It is typical to name the new theme directory ‘parent theme name – child’. In this example the theme directory name is twentyfifteen-child.
- Select where to save new styles. Usually custom style changes that you make to your child theme are saved in the Primary Stylesheet (style.css). You also have the option to save changes in a new stylesheet.
- Select Parent Theme stylesheet handling. Your best option is to let the Child Theme Configurator determine the handling actions unless any of the other options apply to you.
- Customize the child theme name. Although automatically named for you, you have the option to change your child theme’s name, the theme website, the author, and the author website.
- Copy Customizer Settings from parent theme. Read the note and decide whether you want to select this option or not.
Now all that is left to do is click on Create New Child Theme. And that’s it, your child theme is now ready for use.
Step 4: Preview & Activate Your Child Theme
The last thing to do before using your newly created child theme is to preview it and make sure everything is rendering properly.
If everything looks good after you preview it, activate it. To do this, navigate to Appearance > Themes and locate the new child theme.
Then click Activate.
Your child theme is now in working order. If you preview your website it will look as though nothing has changed. That’s because nothing has. Remember, WordPress will look to your child theme first for files to display your webpages. But, since you have not made any custom changes yet, and the files are empty, WordPress will access your parent theme files instead. This is what is being displayed on your website right now.
Creating a WordPress child theme is a beneficial way to maintain control over your website’s overall design and functionality, without all of the problems that come with messing with your theme’s files. You can make any changes you want, experiment with different code, and always know that your website is safe.
And to makes things even better, there is a convenient WordPress plugin that makes creating them even easier than before. With no technical knowledge required and no coding skills needed, everyone that has a WordPress website should consider creating and using a child theme on their website.
What about you? Are you going to create a child theme on your WordPress website? Is there another method that you would like to share that makes creating them easy, even for beginners? I would love to hear all about it in the comments below!