WordPress 4.7 introduced a section in the Customizer called Additional CSS. This section should replace the Custom CSS option that many themes include in their Theme Options, or those plugins created for the same purpose.
Sometimes though, especially for developers, this could be a bad feature, because they don’t want their customers to edit CSS as they want.
How to remove the Additional CSS from the Customizer?
Open the file functions.php in wp-content/themes/your-child-theme-name/ and add this code at the end of the file:
This code will remove completely the Additional CSS section from your WordPress site.
Remove the Additional CSS Conditionally
What if you want to remove it for everyone except administrators? In that case you’d need to check the user role too, and you can do it so:
This code will remove the section for everyone who can’t
manage_options, so everyone who is not Admin or Super Admin.
You can do even more, and leave it only for specific users based on their ID:
This code will remove the Additional CSS from any user that is not ID 1, which usually is the first user created when creating the WordPress site.