Child Themes

Watch This Lesson

What are Child Themes, why do I recommend them, and how do you create one?


Lesson Transcription

Welcome! I’m Leighton, your webmaster. Today, let’s look at child themes. Have you heard of a “child theme”?  Many courses put a lot of emphasis on having a child theme. Let’s explore what child themes are, why I recommend them, and how to implement them.

So first off, what’s a child theme? Well, you recall that WordPress uses themes. Themes are built on top of the WordPress framework to give your website style and design. My theme recommendation, and what you’re learning in this course, is Divi. Divi is an incredibly powerful WordPress theme built by Elegant Themes. Is Divi a child theme? No, not by itself, but you can create your own child theme to work alongside Divi. So why would we do that? Well, one of the best things about Divi is the fact that it’s so well developed and constantly updating. They’re always pushing out new features, improvements and optimizations. So think about that: When you update Divi, the files on your server are replaced with the newly updated ones. Sounds good! But what if you’ve made some modifications to those files? If you had to edit the code for the header, footer, body, edit the functions file or add additional Javascript or CSS to the theme files?  All of those tweaks and modifications would be gone once you update Divi to the newest version. That’s where the child themes come in. They allow you to alter any of the core theme files separately, so your edits aren’t deleted when you update Divi. So if you plan on making advanced customizations to your theme like modifying page templates… adding large amounts of CSS/JavaScript… adding new functions, it is best to make these changes to your child theme without ever having to touch the primary theme files. Now, to be clear, you can add CSS, Javascript, and make plenty of visual edits through WordPress Admin and the Theme Customizer — true! But the more you build websites, the more obstacles you have to overcome, the more you might need to edit a little code to add or fix something. So, child themes are best practices, child themes make editing code easier for you and your project, and they’re extremely simple to create. Let me show you how to create your very own child theme!


So let’s recap child themes!

  1. They are very easy to create
  2. They work alongside your primary theme
  3. They allow you to modify your theme while still updating to the latest version without losing your edits.

I’m Leighton, and now you know… child themes!


Lesson Homework

Once you have finished this lesson, create your own child theme for your website!