change cPanel theme of account through command line
It is fairly simple to change the cPanel theme of an account through cPanel or WHM.
Change cPanel theme through cPanel:
If you are through cPanel, locate the ‘Switch Theme’ box ( usually on the top portion of the panel ) and change to the required theme from there.
Sometimes activating some themes may render cPanel blank or else hide the Switch Theme box in which case you will need WHM or Shell access to change the theme.
Change cPanel theme through WHM:
If you have WHM Access, navigate to Home » Account Functions » Modify an Account and select the account for which the theme is to be changed and click ‘Modify’. Now from the interface which follows, expand the dropdown corresponding for ‘cPanel Theme’ and change the theme to the required theme and ‘Save’ it.
But, is it possible to change it through Commandline.Yes, you can (if you have root access). Sometimes it is necessary to change theme configured for multiple accounts which is not practical or else time consuming to do it for each account individually.
To change the theme only for all accounts
If you need to change the theme of all users who have configured a particular theme to another one, execute the bellow commands as root user.
Be sure to replace the old_theme and new_theme with the themes you need. For eg: to change thepaper_lantern theme to x3, execute the command as below.
To change the theme only for one account
Open the file with cPanel username in the ‘/var/cpanel/users’ directory and change RS field with the new theme name which you want.
The theme configured for the account should be changed now. 🙂