Nextcloud 17 change port from 80 to 443

jamilian

Dabbler
Joined
Nov 18, 2019
Messages
13
Has anyone successfully redirected nextcloud from port 80 to 443 (or another)?
I've tried changing the config.php & the nextcloud.conf files to add port 443 but it doesn't redirect.

Has anyone got a list of steps that need to done to redirect to https and where the changes need to be made?

Thanks
 

samuel-emrys

Contributor
Joined
Dec 14, 2018
Messages
136
Has anyone successfully redirected nextcloud from port 80 to 443 (or another)?
I've tried changing the config.php & the nextcloud.conf files to add port 443 but it doesn't redirect.

Has anyone got a list of steps that need to done to redirect to https and where the changes need to be made?

Thanks
You'll need to add a redirect rule in your web server (apache or nginx) configuration files. I'm not sure how you've installed Nextcloud, but I have a tutorial for achieving this in the guide I wrote for manual installation with apache (see my signature for a link if you need it). If you've installed using the plugin, you'll need to configure nginx. If you search 'nginx redirect 80 to 443' you should get a bunch of results.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
If you installed it using the plugin (which I'd guess since you posted in the plugins forum), the Nextcloud plugin doesn't support SSL at all, so you'd need to start from scratch there. Better would be to either follow Samuel's guide for a manual installation, or use my script for a more automated installation--either will take care of SSL for you.
 
Top