Osclass is a classified ads open-source CMS. It’s close to WordPress in its technology and in its way of fonctionning. In this tutorial, we’ll see how to install it on a LEMP Web Stack. We’re using Linux Ubuntu 16.04, with Nginx, PHP 7.0 & MySQL Server.

At this stage, you should already have configured a host file in /etc/nginx/sites-available/ and created the folders referred in the root location. If it’s not the case, check this guide.

1. Create an SRC Folder

We’re going to create an SRC folder, to keep the sources of our website.

mkdir /var/www/example.com/src

Navigate to this directory:

cd /var/www/example.com/src

Set the webserver as the user of the whole website folder:

sudo chown -R www-data:www-data /var/www/example.com/

2. Install the Latest Version of Osclass

At the time being, the latest version is 3.7.0:

wget https://static.osclass.org/download/osclass.3.7.0.zip

Install unzip:

apt install unzip

Unzip the files to the public_html/ folder:

unzip osclass.3.7.0.zip -d /var/www/example.com/src/public_html

Give the permissions to this folder to the web server:

chown -R www-data:www-data /var/www/example.com/public_html

After that, you can simply go to your website and follow the install of Osclass. If encountering problems with the friendly URLs, make sure you allowed permalinks in your virtual host file. If it’s not the case, check this guide.


Osclass 3.7.0 doesn’t work smoothly on a LEMP stack because of permalinks rewrite rule issues. I encoutered repeated database issues when trying to switch on the “friendly URLs” (let alone enabling a premium plugin like MadHouse SEO).

If you don’t care about SEO and plan on keep “friendly URLs” switched off, you can use Osclass with Nginx without any troubles. But if you do care about it (as you should), it seems advisable to install Osclass website on an Apache2 web server, which will easily handle the .htaccess and rewrite rules.