Is it possible to redirect all traffic from a certain referring URL to a specific page?


Yes, from a technical point of view, it is possible to examine the referrer URL and issue a redirect if it matches.

Whoever is linking into your site may not like this. Presumably, they want their users to see some of your content and have linked to where they think is appropriate. You could certainly do this to correct their mistake or broken link. I wouldn't do this for traffic from a search engine though.

  • Thanks, it an advertiser that linked to the wrong page (homepage instead of specific landing page) Aug 16 '13 at 13:33

You can use RewriteCond %{REMOTE_HOST} or RewriteCond %{REMOTE_ADDR} to set such redirects.

Try something like:

#A.B.C.D is the referrer IP@
RewriteCond %{REMOTE_HOST} ^A\.B\.C\.D
RewriteRule ^(.*)$ http://www.yoursite.com/landingpage.html [NC,L,U,QSA]

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.