eCommerce Expert

Popular Posts

Paul Anthony Gupit

Follow Me

Digital Marketing Philippines Ask Paul Today Digital Marketing Philippines Paul Anthony Gupit
Build and Connect

How to convert htaccess code into nginx syntax.

Basic syntax how htaccess from apache server convert into nginx platform.

This example is used to have a friendly URL path using OpenCart Ecommerce

Sample HTACCESS Code:

RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^ index.php [L]

Converted NGINX Syntax

# nginx configuration

location = /favicon.ico {

location /
{ if (!-e $request_filename){
     rewrite ^(.*)$ /index.php break;


Post a Comment