: HTACCESS Wildcard Subdomain forward to Domain I know this may seem like a duplicate, but I am unable to find a solution. Is it possible to setup wildcard subdomains with htaccess? I have an
I know this may seem like a duplicate, but I am unable to find a solution.
Is it possible to setup wildcard subdomains with htaccess?
I have an example of
test.domain.ca I need to forward to www.domain.ca
I don't have specific 'sub-domains'. so I would need a form of a wildcard. Is this possible to do through HTACCESS?
Any help is appreciated.
More posts by @Bryan171
2 Comments
Sorted by latest first Latest Oldest Best
Short answer: No, it's not possible to setup wildcard subdomains with .htaccess.
To achieve what you want to do, you need to have a wildcard record in your DNS zone file, because your nameserver is where the subdomains are looked up. Also, many hosting companies will not allow you to add a wildcard record, so you'll have to check with them.
Do you actually have a * wildcard record in your DNS zone file? If yes then all you need to do is add an A record into the zone file and point it to the IP hosting your domain.ca now all connections to that specific sub domain will go to domain.com while the other wildcard subdomains will go some place else.
Or in cPanel you would simply create your test subdomain.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.