After connecting a custom domain, how do we prevent Google from indexing the netlify URL (example.netlify.app)?
I’m using Netlify DNS.
Can someone confirm these are the steps?
Step 1. Save a plain text file called
_redirects in my root directory. (Note: my project is just an
index.html file in my root directory. Not using a build command or static site generator).
Step 2. Inside of the
_redirects file write:
https://example.netlify.app https://example.com 301
Is that it? Do I need to write the
www versions of these lines too?
netlify.toml file required too?