vbulletin 4 on nginx web server

After lots of trial and error i believe to have found the best rewrite rules for vbulletin 4 to work with nginx and php5 fpm. For security reasons i recommend setting  php cgi.fix_pathinfo to 0

Let me know if it works for you 🙂

location / {

index index.php index.html;

root /path/to/your/web/root/here;

rewrite ^/((urllist|sitemap_).*\.(xml|txt)(\.gz)?)$ /vbseo_sitemap/vbseo_getsitemap.php?sitemap=$1 last;

if (-f $request_filename) {expires 30d;break;}

if ($request_filename ~ “\.php$” ) {rewrite ^(.*)$ /vbseo.php last;}

if (!-e $request_filename) {rewrite ^/(.*)$ /vbseo.php last;}


location ~* \.(php)$


try_files       $uri /index.php;

fastcgi_index index.php;

root /path/to/your/web/root/here;


include /etc/nginx/fastcgi_params;

fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;

fastcgi_param   SCRIPT_NAME        $fastcgi_script_name;

fastcgi_param PATH_TRANSLATED $document_root$fastcgi_script_name;



Print Friendly, PDF & Email

You may also like...