Webview blank (receives empty HTTP response)

Problem description:
I’m writing a NextJS app. Running the repl opens a Webview which immediately receives an empty HTTP response and displays a completely white page. The compilation ends but the page stays white. I tried refreshing, opening Webview in a new tab, force-refreshing the new tab, closing and opening my repl, logging out and logging in again. Nothing helped.

It worked before. It seems it stopped working after running my repl for a few hours (without any code or config changes). When run locally on my macbook everything works great.

Expected behavior:
When it worked the Webview waited for the end of compilation with a special message (don’t remember what it was) and then displayed the app correctly.

Actual behavior:
Webview receives empty HTTP response from the server and renders a white page.

Steps to reproduce:
Run the repl.

Bug appears at this link:

Brave/MacOS Ventura 13.4.1/Macbook Air

hey @mchalapuk , welcome to the forums!
Can you send a screenshot of your repl?


Can you send a screenshot of your files?

A private repl. Sorry.

The files shouldn’t matter, the code does. If you are storing sensitive data, try storing them in Secrets.
I only need to see the files sidebar.

You’re probably right. There’s no IP in the file names. At least at this point.

Which file is your HTML code in?

app/page.tsx (standard NextJS location)

It worked for some time and then it stopped after running the repl for a few hours without any changes in the code or config.

I think I solved the problem. It started working after I specified ports inside .replit file.

localPort = 3000
externalPort = 80

Thanks @NateDhaliwal


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.