404 on nextjs deployment

Hello,

I am currently trying to publish a nextJS site to netlify, but it shows a 404, link here:
https://animedream.netlify.app/

It is a mono-repo with a root, that contains frontend and backend folder:

  • root →
    ** backend →
    **** backend_stuff
    ** frontend →
    **** package.json
    **** /pages
    ****…

So in the netlify UI I changed the base directory to “frontend”. And Publish Directory to “frontend/.next”

It is installing the dependencies and the “tree” during build that comes up when building next apps can also be seen in the logs.

I already tried to use the two variations of build command mentioned in the documentation for monorepos. It is not helping.

When i download the directory I can see that there is no index.html.

Thanks in advance

Hi @kerem9610,

Thanks for reaching out and welcome to the Netlify Support Forums!

We have a general Support Guide on Page Not Found errors here that may help:

I also found this recent post with a similar issue, if you could try clarnx’s suggesting if the first Support Guide doesn’t help.

If you have any questions, please let us know.

1 Like

Thank you for the response and the links.

I am afraid non of these helped, I looked at them beforehand and checked again now, but I still would not know what I did wrong.

I have a different site deployed on netlify (also with nextjs) and whenenver I download that, there is a index.html file created in the zip. On this repo no index file is created, but I can not find out why. I think that this is the problem

Best Regards

Hey there, @kerem9610 :wave:

If those suggestions did not work, can you please share your repository as well as your most recent deploy log? We will need those details in order to investigate further.

Thanks!