Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Because of my carelessness, I put on the internet. I don't want to lose that traffic, so i want to permanent redirect that url to Can nginx achieve this? thanks

share|improve this question
thanks,how can i close the question,i new here – mlzboy Jan 25 '11 at 1:59
Click the check mark under the answer that was the best. – Martin Fjordvald Jan 25 '11 at 1:59
server {
    rewrite ^ permanent;    

Should do it.

share|improve this answer
Unless you really need the extra folder path - /xxx/index.html – Jon Rhoades Sep 14 '10 at 2:34
in which case rewrite ^$request_uri permanent; would do it. – Martin Fjordvald Sep 14 '10 at 12:40

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.