I have installed the discourse on Digital Ocean


I have add my domain’s non-www verison as hostname… And SSL installed on the same.

My https;//domain.com working fine but when I am trying to open with www version it is showing error.


It will show error because no web server is available to handle the request for the www subdomain.

What domain do You want your forum to open on?


Also, how did You install discourse? Their 1 click install application or the official 30 minutes install guide?


I want to load this without www and when I put url with www it should redirect to non-www.

I have installed using 30 minutes guide.


You should set up a redirect either via cloudflare or directly on Your server to forward all the requests to the non-www version.


Can you guide me how to create redirect in server?


Are You comfortable with SSH?

If so, You can set up a reverse proxy (e.g. nginx) and then set up the redirect from there.

Process will be:

  • Stop discourse.
  • Edit the YAML file (app.yml)
  • comment out the ssl template and expose lines and add the entry for the web.socketed template.
  • Rebuild discourse
  • Install nginx
  • Configure letsencrypt on your domain
  • Configure nginx to forward requests to discourse socket.


not too much comfortable with SSH, but I can do this.


All the best :wink:
Let me know how it goes.