How to add custom styles to WordPress dashboard

In case you want to add some custom styles to the WP dashboard, you’ll have to enqueue a new css file in your (child-)themes functions.php:

function add_admin_style() {
  wp_enqueue_style(
    'admin-style', 
    get_stylesheet_directory_uri() . '/css/admin-style.css'
  );
}
add_action('admin_enqueue_scripts', 'add_admin_style');

 

Leave a Comment

Your email address will not be published. Required fields are marked *