Can my pages directory have a sub-directory

Is a Project Structure such as:

myApp/
* index.html
* /Pages
   * foo.html
   * /Bar
        * Baz.html

myApp/index.html
myApp/Pages/foo.html
myApp/Pages/Bar/Baz.html

Netlify-Instance-Name: # hopeful-meitner-428810
Netlify-Build-Preview : https://deploy-preview-3--hopeful-meitner-428810.netlify.com/
Netlify Error :" # Page Not Found Looks like you’ve followed a broken link or entered a URL that doesn’t exist on this site."
Steps to Reproduce: Attempt to navigate to :Root / pages / photographyPortfolio / product.

This seems like it would be a fairly common project setup , but it would be to hard to reconfigure just curious more than anything!

Please let me know if i was unclear on anything
Working Page From Deploy
Broken Page From Deploy

Hey @miaklwalker

I can navigate to /pages/product.html.

If you want this page to be located at /pages/photographyPortfolio/product.html, you can move the product.html page to the pages/photographyPortfolio/ directory.

Something like:

index.html
/pages
  photographyPortfolio.html
  /photographyPortfolio
    product.html

Hey Jinksi,

Thanks for the reply!

You can navigate to that page because when i updated the branch , I changed the file directory.

Is the same directory structure i had for the project.
I just figured it was impossible and changed the directory :stuck_out_tongue:

I might make a separate branch just to test it

But just to state the obvious , You are correct that would normally be the correct file structure, however , that night i couldn’t get it to work.
So i changed the project to get back to a working state,

i send a build to my designer every night and i didn’t want to send a broken website.

Seriously though thank you for checking this out for me , I’m a fairly experienced Web Developer , but totally new to Netlify!

1 Like

Netlify doesn’t handle this issue much differently than other hosting options, so if you try to navigate to a page that you think is supposed to be there but get an error message, that page isn’t where you think it is.

One easy way to check is to download the deploy and visually / manually check to verify where your files are. You do this by clicking the tiny little download link next to your deploy information.

Netlify will ZIP up your files and offer you a link to download the ZIP file with your entire deploy. Download the ZIP file, unZIP it, and inspect away.

1 Like