osCommerce predates the era when HTTPS was the default for every page. Both the classic 2.3.x branch and the newer Phoenix releases keep two hardcoded configuration files that define the site's base URLs, and those files decide whether a page loads over http:// or https://. When a certificate is installed but the configuration still references plain HTTP, the storefront serves pages with insecure asset references, the browser blocks scripts and images, and the checkout can appear broken even though the payment gateway is fine. Getting SSL right on osCommerce is mostly about aligning three layers: the certificate on the server, the URL constants inside the PHP config, and the redirect rules in .htaccess.

Issuing the certificate and verifying it reaches the store

On the Hostiso managed stack, you do not touch the operating system to get a certificate. Every domain gets automatic coverage through AutoSSL, which provisions a free DV certificate without any manual step. If you want to confirm or force issuance, open cPanel Jupiter and go to Security → SSL/TLS Status. Select your domain and the www alias, then click Run AutoSSL. On DirectAdmin Evolution the equivalent lives under Account Manager → SSL Certificates, where you choose Free & automatic certificate from Let's Encrypt, tick both the bare domain and www, and save.

AutoSSL and Let's Encrypt both validate ownership over HTTP by placing a token under /.well-known/acme-challenge/. osCommerce redirect rules can accidentally capture that path, so if issuance fails, the first suspect is an overly broad rewrite rule forcing everything to HTTPS before the certificate exists. Temporarily remove any custom redirect from .htaccess, re-run AutoSSL, then add the redirect back afterward. Once the certificate is live, load https://yourdomain.com/ directly in a browser and check for the padlock. A valid certificate that still shows a warning almost always means the content layer, not the certificate, is the problem.

Verify which certificate is actually being served by viewing the certificate details in the browser's site information panel. If the common name does not match your domain, you are likely hitting a shared or self-signed fallback because the domain's DNS has not fully propagated to the Hostiso server, or because the document root points somewhere unexpected. Confirm the document root in cPanel under Domains so that the certificate, the files, and the DNS all describe the same destination.

Correcting the osCommerce configure.php URL constants

The heart of osCommerce SSL behavior is two files: /includes/configure.php for the storefront and /admin/includes/configure.php (or /oscadmin/includes/configure.php on some installs) for the back office. Edit them through cPanel's File Manager, not through FTP guesswork, so you can see the exact path. These files are chmod 644 in a healthy install; osCommerce intentionally makes them read-only after setup, so you may need to use File Manager → Permissions to set them to 644 before editing and leave them that way when done.

In the storefront file you are looking for the URL and SSL constants. A correct HTTPS-everywhere configuration looks like this:

define('HTTP_SERVER', 'https://yourdomain.com');
define('HTTPS_SERVER', 'https://yourdomain.com');
define('ENABLE_SSL', true);
define('HTTP_COOKIE_DOMAIN', 'yourdomain.com');
define('HTTPS_COOKIE_DOMAIN', 'yourdomain.com');
define('HTTP_COOKIE_PATH', '/');
define('HTTPS_COOKIE_PATH', '/');
define('DIR_WS_HTTP_CATALOG', '/');
define('DIR_WS_HTTPS_CATALOG', '/');

The admin configure.php mirrors this with its own HTTP_SERVER, HTTPS_SERVER, and ENABLE_SSL entries, plus HTTP_CATALOG_SERVER and HTTPS_CATALOG_SERVER that must also point at https://yourdomain.com. The single most common cause of a half-secure store is that HTTP_SERVER was left on http:// while only HTTPS_SERVER was updated. Because osCommerce builds many links from HTTP_SERVER, any page that is not explicitly flagged as secure then emits an http:// link, which the browser treats as mixed content.

Set both constants to the HTTPS form and set ENABLE_SSL to true in both files. Decide once whether your canonical hostname includes www and use that exact form everywhere; inconsistency between www and the bare domain in these constants creates cookie mismatches that silently log admins out. After saving, clear your browser cache and reload the storefront. If assets now load over HTTPS and the padlock is solid, the configuration layer is correct.

Enforcing HTTPS and avoiding redirect loops on LiteSpeed

LiteSpeed Web Server reads .htaccess natively, so you enforce HTTPS the same way you would on Apache. Add the redirect to the .htaccess in your document root, above the osCommerce SEO rules:

RewriteEngine On
RewriteCond %{HTTPS} !=on [OR]
RewriteCond %{HTTP:X-Forwarded-Proto} =http
RewriteCond %{HTTP_HOST} ^(www\.)?yourdomain\.com$ [NC]
RewriteRule ^ https://yourdomain.com%{REQUEST_URI} [R=301,L]

The X-Forwarded-Proto condition is what makes this proxy aware. When a request passes through a CDN or an upstream SSL terminator, the connection to osCommerce can arrive as plain HTTP even though the visitor used HTTPS. The %{HTTPS} variable then reads off, and a naive redirect rule sends the browser back to HTTPS endlessly, producing the classic ERR_TOO_MANY_REDIRECTS. Checking the forwarded header first lets the rule recognize an already-secure request and stop looping.

If you use Cloudflare with its Flexible SSL mode, the loop is guaranteed because Cloudflare talks to Hostiso over HTTP while telling the browser it is HTTPS. Switch the Cloudflare SSL/TLS encryption mode to Full or Full (strict) so the origin leg is also encrypted, since AutoSSL already gives you a valid certificate at the server. For osCommerce to trust the forwarded protocol internally, some Phoenix installs expose a setting, but on 2.3.x you can nudge PHP by adding a line to a .user.ini in your document root is not sufficient for this; instead rely on the .htaccess condition above, which is the supported path on a LiteSpeed shared account.

Keep one canonical host. If both www and non-www resolve, pick one target in the RewriteRule and let the other redirect into it, matching whatever you placed in configure.php. A mismatch here is the second-most common loop trigger because osCommerce redirects to its configured host while .htaccess redirects to the other.

Tracking down residual mixed content and proving the fix

After the certificate, config, and redirects line up, a store can still show a broken padlock because of content stored in the database or baked into templates. Product descriptions, banner HTML, and manufacturer image URLs frequently contain absolute http:// links typed in years earlier. Open the browser developer console, reload a storefront page, and read the mixed content warnings; each one names the exact insecure URL so you know whether it comes from an image, a stylesheet, or an embedded script.

For database-stored links, use phpMyAdmin from cPanel to search and correct them rather than editing rows blindly. Select your osCommerce database, open the SQL tab, and run targeted updates against the tables that hold HTML, for example products_description for catalog copy:

UPDATE products_description
SET products_description = REPLACE(products_description, 'http://yourdomain.com', 'https://yourdomain.com');

Repeat for banner and category tables as the console warnings dictate, and always take a backup through phpMyAdmin → Export before running any REPLACE. The safest absolute references are protocol-relative or fully HTTPS; converting hardcoded origin links to https:// removes the warning permanently. For assets referenced in template files under /templates/ or legacy header boxes, edit them in File Manager and replace the scheme the same way.

When the console is clean but you still see intermittent insecure requests, check for third-party widgets such as currency converters or older analytics snippets that call out over HTTP. Those are edited in the osCommerce Admin under Modules → Header Tags or the relevant content module, where you can update the embed to its HTTPS equivalent. If a vendor only offers HTTP, remove it rather than letting it poison the padlock for the entire store. Once every warning is resolved, re-run SSL/TLS Status in cPanel to confirm the certificate remains valid, then test checkout end to end to ensure cookies persist across the secure session. A store that keeps a stable padlock from the catalog through the payment page has all three layers aligned, which is the real objective.