Are you using nginx or apache?
Is it shared hosting or dedicated server?
Got an urgent question that’s keeping you up at night? There might just be a magical inbox ready to help: khnaz35@gmail.com
Enjoy nature
As far as I know, no rewrite rules can be used in htaccess when that directive is not set and you cannot set that directive in htaccess if not allowed by the server configuration. If therefore you are not allowed to use rewrite rules by your provider, maybe go elsewhere.
Perhaps your provider is willing to enable the SymlinksIfOwnerMatch directive instead?
Apache errorlog quote:
Options FollowSymLinks and SymLinksIfOwnerMatch are both off, so the RewriteRule directive is also forbidden due to its similar ability to circumvent directory restrictions
Find a new host?
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
Opencart Expert | voldemaras@gmail.com
Extensions for Opencart @ https://www.opencartextensions.eu / or Opencart Marketplace
Need Custom Module? debug third party module or simply have any question related to Opencart? feel free to contact directly for a live chat session:) - INSTANT LIVE CHAT
FollowSymlinks is enabled by default, but it no longer if your provider disables it, and it is a security risk on shared servers.
I'm sure they will enable SymLinksIfOwnerMatch instead though or they won't have many customers.
Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig
Perhaps they've fixed the issue but hasn't come back to tell us.
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
If your hosting provider does not support the FollowSymlinks directive (common in shared hosting environments due to security restrictions), you can still enable SEO-friendly URLs in OpenCart by using the SymLinksIfOwnerMatch directive or adjusting your .htaccess configuration. Here's how:
1. Verify Hosting Environment
Confirm with your hosting provider whether they allow:
SymLinksIfOwnerMatch (often supported as a secure alternative to FollowSymlinks).
.htaccess rules and mod_rewrite functionality.
2. Update .htaccess
If FollowSymlinks is not supported but SymLinksIfOwnerMatch is allowed, modify the .htaccess file in your OpenCart installation directory.
Updated .htaccess Example
Code: Select all
<IfModule mod_rewrite.c>
Options +SymLinksIfOwnerMatch
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?_route_=$1 [L,QSA]
</IfModule>
Log in to your OpenCart Admin Panel.
Go to System → Settings → Edit Store.
Under the Server tab, set Use SEO URLs to Yes.
Save your changes.
4. Test SEO URLs
Ensure that your .htaccess changes are working by visiting a product page. The URL should be SEO-friendly (e.g., yoursite.com/product-name instead of index.php?route=product/product&product_id=1).
If the URL doesn’t work, verify that mod_rewrite is enabled on your server.
5. If .htaccess or mod_rewrite is Disabled
If your provider does not support .htaccess or mod_rewrite, you have two options:
Switch Hosting Providers:
Choose a host that supports modern configurations (e.g., FollowSymlinks or SymLinksIfOwnerMatch).
This may be the easiest long-term solution if your hosting provider is restrictive.
Use Non-SEO URLs:
Keep SEO URLs disabled and focus on optimizing other aspects of your site for SEO.
6. Communicate with Your Host
Ask your hosting provider to enable SymLinksIfOwnerMatch if it’s not already enabled. Many providers are willing to make this adjustment upon request.
Example Request to Your Host:
Dear Support,
I am attempting to enable SEO-friendly URLs in my OpenCart store but have discovered that the FollowSymlinks directive is not supported on my hosting plan. Could you please enable the SymLinksIfOwnerMatch directive as a secure alternative? This will allow me to use SEO-friendly URLs without compromising server security.
Users browsing this forum: No registered users and 30 guests