Hello Support team and Community, this is more of a general question.
I have a domain thats bought from NameCheap and the website is hosted on WordPress. Now I want to redirect everything in that domain to another domain that has a Github repository and is linked to Netlify.
Is it possible if i create a new site in Netlify and add only the netlify.toml
file and then add the custom domain that is bought in WordPress to that site, would it redirect?
So as an example in NameCheap I bought two domains:
“https://wordpresshosteddomain.com/”
“https://www.netlifyhostedwebsite.com/”
In Netlify, I already have a site setup for this domain “https://www.netlifyhostedwebsite.com/”. Now I want to redirect the wordpresshosteddomain to the one in Netlify.
So after reading the documentation, I understood I can simply setup a new site that would only contain the netlify.toml
link it to the custom domain “https://wordpresshosteddomain.com/” and in the file I can add the following, and it should work:
# Fallback Redirect
[[redirects]]
from = "https://wordpresshosteddomain.com/*"
to = "https://www.netlifyhostedwebsite.com/"
status = 301
Would this redirect to the website hosted in Netlify?