Can't deal with phx endpoint url

Hello,
In production config I have:

config :app_phx, AppPhxWeb.Endpoint,
  url: [scheme: "https", host: "www.website.net", port: 443]

However after running the prod mix server PORT=5000 MIX_ENV=prod mix phx.server I see that my Endpoint wants:

22:35:09.203 [info] Access AppPhxWeb.Endpoint at https://website.net

There is no www infront of website.net. Why?
When I type my website in the url bar in chrome Endpoint gets https://website.net as it should be and the site works, however in firefox browser:

22:36:26.042 [error] Could not check origin for Phoenix.Socket transport.

Origin of the request: https://www.website.net

This happens when you are attempting a socket connection to 
(...)

(that www.)
If necessary → I’m using proxy via nginx, config:

server {

      server_name website.net;  # removed www.website.net (should I?)

      location / {
                proxy_pass http://167.172.163.148:5000/;


                proxy_set_header Upgrade $http_upgrade;
                proxy_set_header Connection "upgrade";
                proxy_http_version 1.1;
      }

 
}

# other functions managed by Certbot



}

I tried via nginx to redirect ,www requests, without luck:

server {
  server_name www.website.net;
  return 301 $scheme://website.net$request_uri;
}

I know this is a bad approach, just for testing.
What are your thoughts, possible solutions?

Best Regars, ykostov