Redirect non-www to www on nginx server -


i want redirect https://example.com https://www.example.com. read multiple questions here , articles how doesn't seem work. here tried:

server{     listen 80;     listen 443 ssl;     server_name example.com;     return 301 $scheme://www.example.com$request_uri; } 

i set record name www points ip.

i use cloudflare if important know ...

any ideas i'm doing wrong?


Comments

Popular posts from this blog

python - Operations inside variables -

Generic Map Parameter java -

arrays - What causes a java.lang.ArrayIndexOutOfBoundsException and how do I prevent it? -