Build on Reign with a child theme
Why direct edits to Reign are lost on update, how to get the official child theme, and what to put in it versus in Custom Code.
Any file you edit directly inside reign-theme is overwritten the next time
Reign updates, with no warning. A child theme is a separate directory that
loads on top of Reign, so your changes survive updates instead of being
replaced by them.
Your Customizer and Reign Settings choices are not at risk either way. They
live in the database, not in theme files, so an update never touches them.
A child theme is for template edits, custom PHP and anything you would
otherwise put directly into reign-theme.
Get the official child theme
Go to Reign Settings > Tools. The Child theme card has a Download child theme button. It downloads the official Reign child theme package from Wbcom’s GitHub releases, ready to activate. It is a starter package, not a copy generated from your current site: it does not capture your existing customizations, because those already live safely in the database.
The same Tools screen has a System status card, which reports whether a child theme is currently active, alongside your PHP, WordPress and Reign versions. Copy it into a support ticket when you open one.
Activate it
- Upload the downloaded zip via Appearance > Themes > Add New > Upload Theme, then activate it.
- Reign Settings, the Customizer and every saved setting stay exactly as they were. Activating a child theme does not reset anything.
- Confirm on Reign Settings > Tools that the Child theme status now reads Yes.
Enqueue your child stylesheet
Reign does not automatically load a child theme’s style.css as a
stylesheet. WordPress only reads that file’s header comment for theme
metadata unless something enqueues it, and Reign’s own CSS ships as
compiled bundles rather than through style.css. Enqueue it yourself, and
depend on Reign’s main stylesheet handle, reign_main_style, so your rules
always load after Reign’s and can override them:
add_action( 'wp_enqueue_scripts', 'reign_child_enqueue_styles' );
function reign_child_enqueue_styles() {
wp_enqueue_style(
'reign-child-style',
get_stylesheet_uri(),
array( 'reign_main_style' ),
wp_get_theme()->get( 'Version' )
);
}
Your child theme’s style.css still needs the standard header WordPress
requires to recognise it as a child theme, including a Template: reign-theme line matching Reign’s directory name.
What belongs in the child theme
- Template overrides. See template overrides for the directory rules, including the one BuddyPress-specific exception.
- Custom PHP: new hook callbacks, filters, shortcodes.
- CSS beyond a handful of rules, or CSS you want under version control.
What belongs in Custom Code instead
Customizer > General > Custom Code has three fields: Tracking Code (added to the site header, for things like analytics or a Facebook Pixel), Custom JS: Header and Custom JS: Footer. Use these for small, site-wide snippets that do not need file editing or a child theme at all, and that you want a non-developer site owner to be able to find and edit later from Reign Settings rather than in code.
If a snippet grows into something with real logic, conditions, or more than a few lines, move it into the child theme instead. That keeps Custom Code for what it is meant for, and keeps anything more substantial in a file you can put under version control.
Hooks and the REST API
Once your child theme is active, the hooks reference and the REST API cover the extension points available to code running in it.