RewriteEngine on # test if rewrite should stop for # special directories RewriteRule ^(favicon.ico|robots.txt) - [L] RewriteRule ^(images|skins|auto|files|stats)/.*/? - [L] # all php scripts. RewriteRule \.php$ - [L] # do the rewrite RewriteRule ^wiki/?(.*)$ /index.php?title=$1 [L,QSA] RewriteRule ^/?(.*)$ /index.php?title=$1 [L,QSA]