MyBB Tutorials

Remove index.php from URL

Submitted by Aoki, , Thread ID: 40

Thread Closed
Aoki
retired
Level:
83
Reputation:
348
Posts:
7.89K
Likes:
2.3K
Credits:
1.7K
15-01-2015, 07:10 AM
#1
This is a very simple way to remove the index.php from your URL. Please note that this only works if you are running an Apache web server and mod_rewrite is enabled!
Just add the following lines to your root .htaccess file (directly after RewriteEngine On):

Code:
<pre class="_prettyXprint">
RewriteCond %{IS_SUBREQ} false
RewriteRule ^index.php$ http://www.example.org [R=301,L]
</pre>

Of course you have to replace http://www.example.org with your own MyBB installation.

Users browsing this thread: 1 Guest(s)