404 error on all pages but homepage

Assuming you are on Linux, you need to make some changes in apache2.conf file stored in /etc/apache2 directory.

Open the file with root permissions, you will find the code given below in the file.

<Directory /var/www/>
    Options Indexes FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>

Here just change the AllowOverride None to AllowOverride All, save the file & restart apache.

This will work in most of the cases.

Leave a Comment