Redirect all subdomains to main domain

Hey! I’m trying to create a redirect for all all traffic on our secondary domain to our primary domain, but it’s not for the subdomains. Could someone point to what I’m doing wrong?

https://secondarydomain.com/* https://domain.com/:splat 301! https://*.secondarydomain.com/* https://domain.com/:splat 301!

Hi, @pitch. It isn’t possible to add a wildcard in the domain name portion of the redirect rule. Wildcards can only be used in the path portion of the URL.

If you want to redirect multiple subdomains, a rule must be made for each one:

https://subdomain-1.secondarydomain.com/* https://domain.com/:splat 301!
https://subdomain-2.secondarydomain.com/* https://domain.com/:splat 301!
https://subdomain-3.secondarydomain.com/* https://domain.com/:splat 301!
https://subdomain-4.secondarydomain.com/* https://domain.com/:splat 301!