Apache on Ubuntu Invalid command ‘RewriteEngine’

Was getting the an error in the error log:

.htaccess: Invalid command ‘RewriteEngine’

and the site with a .htaccess file wasn’t working (“Internal server error”).

Turns out that the mod rewrite was not enabled and can be enabled with:

sudo a2enmod rewrite

Leave a Reply

Your email address will not be published. Required fields are marked *