ServerAlias using wildcard done right


Dec 5, 2004
I've read a lot of posts on this issue, but I still can't seem to find the correct way.

I need to add a wildcard for the ServerAlias for some users and I don't want to worry that the some point my change will be overwritten by some script. So if possible, can someone from cPanel staff please provide clear instructions on what needs to be done?

There is no such option in cPanel interface. I understand one option is to edit /var/cpanel/userdata/*/ and add the wildcard there, but apparently this file is overwritten with the next build.

Thank you very much for your time.


Release Manager
Staff member
Aug 12, 2010
cPanel Access Level
Root Administrator
I am not aware of a specific process that would cause the /var/cpanel/userdata/*/ ServerAlias to be overwritten after the changes have been properly distilled, but you are certainly free to add additional ServerAlias lines via an individual VirtualHost include file:


${USER} should be replaced by the cPanel account's username
${DOMAIN} should be replaced by the domain in the VirtualHost