If you accidentally remove the ‘www’ shortcut to public_html folder in cPanel, please follow tutorial below to recreate it.
1) Go to cPanel user folder
cd /home/user/
2) Create back the symbolic link
ln -s public_html www
3) Change the ownership of the www sym link to the cPanel user’s ownership
chown -h user.user www
4) Done. Do a ls -al to double check the sym link.
ls -al