Pak Jiddat - Innovative Software Services

Read: In the name of thy Lord Who createth, Createth man from a clot. Read: And thy Lord is the Most Bounteous, Who teacheth by the pen, Teacheth man that which he knew not. Nay, but verily man is rebellious That he thinketh himself independent!. Lo! unto thy Lord is the return. (Sura Alalaq 96:8)

Redirect http to https with Nginx

Created On: 22 Nov, 2017: 19:15:04 - Tags : web servers


To redirect http urls to https with Nginx web server, we need to add following inside a server block or location block: return 301 https://$host$request_uri;

Related Articles

  1. Redirect http to https with Apache
  2. Creating and Installing Apache Self Signed Certificate
  3. Using flags with rewrite rule
  4. Redirecting without mod_rewrite using regular expressions in htaccess
  5. Generate Certificate Signing Request (CSR) for ssl certificates
  6. Disabling output buffering with mod_fcgid
  7. Configuring Apache mod status
  8. Allowing Cross Origin Requests using htaccess
  9. Access control directives for Apache
  10. Blocking visitors by http method using LimitExcept Apache directive
  11. Passing query parameters to proxy server in Nginx
  12. Use of Preflight request in HTTP Cross Origin Resourse Sharing (CORS)
  13. Using RewriteCond directives