Routing on Domain

Is there any way to route based on a domain/URL? We are using an AWS managed service that gives us an endpoint we want to route traffic through the VPN to it. The IPs behind this endpoint can change as it’s an AWS managed service so we don’t want to base routing rules off of them.

There’s no option for routing domains, all routes must be IP addresses.