I have an Ubuntu 16 VPS running (LAMP) Apache+WordPress .

the permalinks are not functioning properly as i'm receiving 404 errors.

Hello, the following .htaccess files exist on the server:

/var/www/html/wp-snapshots/.htaccess /var/www/html/wp-includes/.htaccess /var/www/html/.htaccess /var/www/html/wp-content/plugins/litespeed-cache/lib/vendor/mrclay/minify/.htaccess

/var/www/html/.htaccess contains, the code below.

The WordPress settings are also set to " Post name ", and the url is still returning a 404 error:

  • 1
    You might want to update the permalink settings, even if you didn't change them. This is a very popular problem, with a very simple solution.
    – Johansson
    May 8, 2018 at 8:11

2 Answers 2


Though there are many possibilities like enable Apache web server with the mod_rewrite or check permissions to allow Wordpress to write to the .htaccess file.

It will be helpful for you, if you go through this for more details. https://codex.wordpress.org/Using_Permalinks


Create .htaccess file in your WordPress folder and put below values:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress

Get more information about .htaccess in WordPress https://codex.wordpress.org/htaccess


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.