WordPress is one of the most popular content management systems (CMS) in the world, offering a wide range of customization options. One aspect that a user may want to customize is the color scheme of the admin panel. In this article, we will look at different methods that allow you to change this part of WordPress.
1. Changing the color scheme via user profile settings
The basic method of changing the color scheme in the administration panel is to use the option available in the user profile. Here's how to do it:
- After logging in to WordPress, go to the admin panel and click on your username in the upper right corner, then select “Edit Profile”.
- Scroll down to the “Color Scheme” section. There you will find several options available.
- Choose the color scheme that suits you best.
- Save your changes by clicking the “Update Profile” button.
2. Personalize the color scheme with the plugin
If the default color schemes do not meet your expectations, you can use a plugin. For example, the “Admin Color Schemer” plugin allows you to create your own color schemes.
After installing and activating the plugin, go to “Settings” > “Admin Color Schemer”. Here you can customize the four primary colors that will be used in your new color scheme.
3. Using CSS code to change colors
If you are a more advanced user, you can use custom CSS code to change the colors of the admin panel. You can do this by adding the following code to the file functions.php
your theme:
function custom_admin_colors() { echo '
#wpadminbar { background-color: #000; }
.wp-block { background-color: #fff; }
'; } add_action('admin_head', 'custom_admin_colors');
This code will change the color of the admin toolbar to black and the background color of the blocks to white. You can adjust these values to suit your preferences.
4. Create your own color scheme using PHP functions
An even more advanced solution is to create your own color scheme using PHP functions. Below is an example of a function you can add to your file functions.php
:
function custom_admin_color_scheme() { wp_admin_css_color( 'custom', 'Custom', get_stylesheet_directory_uri() . '/admin-colors.css', array('#202020', '#454545', '#e14d43', '#d5953f') ); } add_action('admin_init', 'custom_admin_color_scheme');
This feature adds a new color scheme called “Custom” that uses a CSS file admin-colors.css
located in your theme directory. The four-color table defines the main colors used in the scheme.
Remember that personalizing WordPress by changing its color scheme is not only a matter of aesthetics, but can also improve the user experience. Choose colors that are consistent with your brand and are easy on the eyes, and WordPress will become even more pleasant to use.