This site utilizes JavaScript to function correctly. Looks like it's disabled on your browser. Please enable it for your best experience.

For instructions on enabling JavaScript, click here

Skip to main content

Just Host Web Hosting Help

Protect Specific Pages With SSL

Overview

This article will show a way to protect specific pages of your website with SSL. This may have benefits for SEO and can be used on pages that contain forms, shopping carts or any other page where users might enter sensitive information.



Access The File Manager

To setup SSL protection on specific pages you must edit the .htaccess file which can be accessed from the file manager. The steps will explain how to access the file manager.

  1. Login to your Just Host account.
  2. Go to your hosting tab.
  3. Click the cpanel link underneath the hosting tab.
  4. Under the file management section click on File Manger.
  5. In the directory selection popup select the Show Hidden Files Option and click go.
  6. In the File Manager navigate to the public_html folder.
  7. Select .htaccess file

Edit The .htaccess File

Once you have found the .htaccess file in the file manager these steps will explain how to edit the file to add protection.

  1. Right click on the .htaccess file and select Code Edit
  2. At the top of the file insert the following code:
    RewriteEngine On
    RewriteCond %{HTTPS} off RewriteCond %{REQUEST_URI} /[SSL Requested page]/
    RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R,L]
  3. On the 3rd line of code which says "RewriteCond %{REQUEST_URI} /[SSL Requested page]/" change [SSL Requested page] to the page you want to protect.
    Example: If contact_us was the name of a page you wanted to protect you could use "RewriteCond %{REQUEST_URI} /contact_us/"
  4. Click the Save Changes button in the top right side.
  5. Check your website to ensure it is functioning as expected.
Knowledgebase Article 111,208 views bookmark tags: htaccess pages specific ssl


Was this resource helpful?

Did this resolve your issue?


Please add any other comments or suggestions about this content:





Recommended Help Content

How to force https on entire website.
Knowledgebase Article 370,385 views tags: htaccess ssl website

What is the .htaccess file and where can I find more information?
Knowledgebase Article 2,072,510 views tags: htaccess tips tricks

How to use a WildCard SSL Certificate
Knowledgebase Article 212,375 views tags: htaccess reseller ssl subdomain subfolder wildcard

Related Help Content

I need to protect the /images folder to not show images when people type in the correct URL like www.mydomain.com/images/ to protect from prying eyes.
Knowledgebase Article 162,533 views tags: hotlink htaccess protection

How do I Password Protect a single file on my website?
Knowledgebase Article 272,648 views tags: file passwd password prompt protect secure single

If suddenly when you go to your page, you get nothing on the page. You can still get HTML to display, just not PHP. To serve HTML pages to browsers, we don't associate the Apache processes with your 2
Knowledgebase Article 181,648 views tags: blank page php

An overview of what shopping carts are available and why you would want to use one.
Knowledgebase Article 108,766 views tags:

General Information about SSL Certificates
Knowledgebase Article 554,513 views tags: accept card cert certs credit ecommerce encryption layer online payments secure shopping socket

When I try to log into my OSCommerce shopping cart using https://secure.Justhost.com/~username url, my shopping cart isn't the same. It is as though I have 2 carts, one for HTTP (unsecure) an
Knowledgebase Article 186,213 views tags: commerce cookie oscommerce ssl

This article explains error pages and how they can be customized.
Knowledgebase Article 312,943 views tags: customize pages

How do I password protect a folder on my website?
Knowledgebase Article 297,347 views tags: folder password protect

** Google ad credits are only available to customers in the United States, Canada, and the United Kingdom at this time.

¹ VAT (Value Added Tax) is not included in our advertised price and will be charged separately and itemized on invoices and billing information. Standard VAT rates based on EU Member State regulations may apply. Learn more.