NextCloud/Pain points/https

From Adam Meola - wiki
< NextCloud‎ | Pain points
Revision as of 19:08, 15 March 2021 by Adam (talk | contribs)
Jump to navigation Jump to search

Forcing https

It is of course strongly suggested that you always run this sort of platform behind https (so snoopers can't directly see the traffic)...

Assuming that you have an SSL cert on the domain, you'll want to redirect all http traffic to https.


This is done nice and easily, by amending the .htaccess file in the root of the NextCloud installation.


Add the following:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]