I see following bug (closed as invalid): https://trac.nginx.org/nginx/ticket/1067 Comment from there: Using variables in proxy_pass implies, that the URI specified is a full one Posted at Nginx Forum: https://forum.nginx.org/read.php?2,279953,279955#msg-279955