1. Home
  2. Wordpress
  3. Add body class

Append css class to body using filter.

#wordpress#php
function add_your_body_class($classes) {
    $classes[] = 'new-class';
    return $classes;
}
add_filter('body_class', 'add_your_body_class');
copy
Full Wordpress cheatsheet