Ioannis Antypas
Ioannis Antypas

Reputation: 1

How to redirect to https with .htaccess

I want to redirect everyone that enters my website into https://www.yogozy.com/ Now whenever I type yogozy.com on the search bar it takes me automatically to yogozy.com but since I have my SSL activated I want everyone that enters my website to be redirected to https://www.yogozy.com

Is that possible to do using .htaccess?

If yes can you please guide me through the process?

Any help is appreciated. Thank you!

Upvotes: 0

Views: 32

Answers (1)

Luis Gutierrez
Luis Gutierrez

Reputation: 11

Similar to this post, you can try the following:

 RewriteEngine On
 RewriteCond %{HTTPS} !=on
 RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [R,L]

Upvotes: 1

Related Questions