Blank page with Next.js


I’m building my site with Next.js.
My site works fine with local environment.
But I found the blank page with production environment.

The url below is blank.

But other path like sign in url is working.

Also, I can see “Failed to load resource: net::ERR_HTTP2_PROTOCOL_ERROR” error at Chrome debug tool.

I hope someone can help me.
Thank you.

Hey there, @naogify :wave:

Thanks for reaching out! Sorry that you are encountering obstacles with your site. I confirm that I see the blank deploy and the functioning url. Can you please share your build settings and deploy logs?

1 Like

Hi @hillary :wave:

Thank you for your response!
I just fixed the problem by removing index.html at public folder. But, I still haven’t get the reason why I could solve it . . . :thinking:

But Thank for your support!

1 Like

I got the answer from Netlify support team. Now, I totally understand the reason.

Next.js builds the index.html for you during the next build process. However, the contents of the public directory are copied after the site has finished building. So, it gets overwritten and causes issues.

1 Like

Thanks for coming back and letting us know! Happy building :rocket: