RewriteEngine On RewriteCond %{HTTP_HOST} !^www\.mydomain.com/foruns/$1 RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/forums/$1 [R=301,L]