Problem with reverse proxy

I have been able to fully setup my nextcloud server on ubuntu but, I only have one problem.
I use a free domain from No-IP and I have this problem. I don’t know how to deal with this, because in the documentation there is no real help for my problem. I did some tinkering with reverse proxy in the server, but none of them fixed my issue.

Here is just a full picture.

→ These settings (trusted_proxies and forwarded_for_headers) ← are normaly responsible to get rid of that problem.

Hope this solves your problem.
Much luck,

Thank you for your reply.
I looked at both the trusted_proxies and forwared_for_headers and none of them fixed the problem. Now, it is maybe that I used them incorrectly or that they don’t fix the problem. I am new to nextcloud so I don’t know how to really do this.

I have exactly the same problem and I have no idea how to use these trusted_proxies and forward_for_headers stuff. I understand that you have to write that into the config.php file insidethe config directory, but that’s about it and the Nextcloud documentation isn’t really helpful for people like me who have very limited knowledge of php and other database codes. I have tried re-installing Nextcloud on my web hosting account for the last 3 days and it systematically comes up with the same issue. And this occurs whatever network I’m using. So, I’m at a complete loss.

I have tried the solution suggested here_ Problem configuring a proxy on my web-based NC 27.1.3 - #2 by ernolf. But to no avail. The parameters of the extension are impossible to fill.

Hi Siman,
looks like your NC webapp is behind a web proxy, I’m assuming you are using a proxying web server as a front server while Nextcloud is served by another Apache (or nginx) instance. I also assume the front web server is in the same private subnet of the NC server.

In such scenario the web server should have an internal IP (i.e.192.168.x.y) reachable by the NC instance, you should be able to add that IP in NC’s trusted_proxies configuration.
Then you should also set the forwarded-for headers in the proxy configuration in order to make sure Nextcloud sees the correct client IP’s instead of the proxy’s internal IP address.
In my case (nginx) I’ve added the following to my proxy configuration:

    proxy_set_header Host $http_host;
    proxy_set_header X-Forwarded-Host $http_host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;
    add_header Front-End-Https on;

If you’re using Apache as front web server, there are similar directives to achieve the exact same result.
Hope this helps. Cheers,