How to Redirect 'http' to 'https' in NGINX ?
Here we will learn how to redirect all http request to https in nginx server. Assuming you have successfully installed ssl and can access https manually.
First Method:
This is the easiest one ! 🙂
Find below codes in your websites vhost.
server {
listen *:80;
server_name domain.tld www.domain.tld;