Fonts 404 error



My site:

I am trying to add some fonts to a website. They appear to load correctly in chrome, however, I get 404 errors saying the files are missing. They do appear in firefox without console errors. I am using the netlify victor-hugo boilerplate.

The font stylesheets are being imported into the main.css. The following pictures show the project structure and css.


project tree

font stylesheet


Hello, could you try using /fonts/ instead of …/fonts? Make sure the fonts directory is at the root level of your static assets directory


I’m not sure the assumption you’re using for that path will work. Like @Weru says, put your fonts in /static in your project (under “site” for you I think), which gets merged by Hugo to the root of your site on publish.

Reference the files accordingly.