How to config Nginx redirect HTTP to HTTPS

Nowadays, SSL protocol is becoming more popular for webmasters who want to security through an encrypted connection their server. After install SSL, how can you redirect HTTP to HTTPS ? Oh, this post will help you.

how-to-confict-nginx-redirect-http-to-https

HTTPS(Hyper Text Transfer Protocol Secure) protocol is a secure version of HTTP which can used for secure transactions of ecommerce sites, it is also make your site have good ranking in Google. In this tutorial we will show you how to redirect all traffic from HTTP to HTTPS using nginx rewrite.

In nginx.conf, just add or modify like bellow:

When finish you will have something like this:

Now Restart Nginx

Very easy right ? I hope this simple tip can help you 😀

Tags:,

Leave a Reply

50% off over 500 items. Grow your toolkit for all projects. Design, build, produce.Cyber Monday