Home
Support Forums

File missing from deployment

I setup my sites with Brave Creator’s Rewards for crypto donations through the Brave browser. Domain verification through Brave is done by adding a text file in the following path at the hosting root.

.well-known/brave-rewards-verification.txt

The link to my verification file currently 404s: https://asexualityconference.org/.well-known/brave-rewards-verification.txt

I deploy my site by building locally and drag\dropping the dist folder onto Netlify’s deployment page. Deployment succeeds and the rest of the site works.

6:52:23 PM: Creating deploy upload records
6:52:23 PM: Starting post processing
6:52:23 PM: Post processing - HTML
6:52:24 PM: Post processing - header rules
6:52:24 PM: Post processing - redirect rules
6:52:25 PM: Post processing done
6:52:25 PM: Site is live :sparkles:

It seems like either the deployment process is excluding .*/ or netlify’s server rules aren’t handling the url path correctly. I am not aware of anyway that I can troubleshoot this further on my own though.

Any ideas?

Welcome to the forums @royce

I believe the only way (currently) to have a .well-known directory is to deploy from git. At least from my testing.

Netlify is ignoring directories starting with a dot (the . character). There are “reasons” this is done but that is what is happening.

The workaround for this is two steps:

  1. Deploy the file without the dot in the directory name (so /well-known/brave-rewards-verification.txt instead of /.well-known/brave-rewards-verification.txt).
  2. Create a redirect for the dot path pointing to the path that was deployed.

In the _redirects file syntax, the redirect would look like this:

/.well-known/brave-rewards-verification.txt    /well-known/brave-rewards-verification.txt 200

If that doesn’t work or if there are other questions, please let us know.