Redirect from https://www.sub.domain.com?

Hello.
How to redirect https://www.sub.domain.com to https://sub.domain.com ?

I need this redirect because CF’s SSL doesn’t work for sub subdomain (ERR_SSL_VERSION_OR_CIPHER_MISMATCH)

Because of that I can’t use letsencrypt ssl on sub subdomains… Because it fails checking www with https redirect enabled…