Rewrite with permanent and last

neubyr neubyr at
Wed Nov 19 22:37:11 UTC 2014

Is it possible to rewrite URL with HTTP 301 and make that last rule in
current ruleset? For example, in apache one can use flags "[R=301,L]" , but
how can one do it in nginx? I tried using following, but it returned syntax

Config: rewrite /members /users permanent last;

Error: nginx: [emerg] invalid number of arguments in "return" directive in

Any help?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the nginx mailing list