What is htaccess and How to Use It?
Force HTTPS
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]Disable Directory Listing
Options -IndexesCustom Error Pages
ErrorDocument 404 /404.html
ErrorDocument 500 /500.htmlProtect wp-config.php
<Files wp-config.php>
Order Allow,Deny
Deny from all
</Files>
Was this helpful?
Thanks for your feedback!