In the event that you receive an error message stating Error: The WebSocket handshake failed
when trying to use the Terminal feature in cPanel, in our experience this can happen if you are accessing cPanel via a proxy sub-domain, such as https://cpanel.yourdomain.com
To fix this, we suggest trying the following links to access cPanel -> Terminal:
https://$ipaddress:2083
https://$domain.tld/cpanel
https://cpanel.$domain.tld
If none of those links work, try disconnecting from any proxies or VPNs that you may be using, and also trying with other web browsers.