It’s better to style the /wp-admin of WordPress from your theme because it’s portable and upgrade-proof. Keeping all customizations in ONE place is always a good idea in web development.
How to style WordPress admin backend /wp-admin from your theme?
- Add this hook to the functions.php of your theme:
function customAdmin() { ?><link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_directory'); ?>/wp-admin.css" /><?php } add_action('admin_head', 'customAdmin');
Which effectively adds a stylesheet to the header of every /wp-admin page.
- Create a text file named wp-admin.css in your theme directory.
- Write the customization styles in wp-admin.css.
That’s it. Now you can freely customize the look and appearance of the WordPress admin backend from within wp-admin.css in your theme directory.