How to Set Up WordPress Pretty Permalinks in IIS6

WordPress supports pretty permalinks, which are user-friendly URLs for your posts, pages, tags, etc. They work perfectly fine if you have your WordPress installation running on Apache web server and are being processed by an Apache add-on module called mod_rewrite. However, if you install your WordPress under IIS, you will find that your permalinks are not working anymore and you start getting 404 Page Not Found errors. This is happening because mod_rewrite will take the friendly URL and redirect your request to index.php, passing the right parameters along, and, since you are running WordPress under IIS and not Apache, it is not happening anymore. Luckily, there is a very easy fix for that. In order for you to use pretty permalinks in WordPress under IIS, you will need to install an ISAPI (Internet Server Application Programming Interface) filter and tell your blog website to use it. The function of the ISAPI filter that you are going to install is the same as that of mod_rewrite. Now, let’s get to it and you will have your pretty permalinks in no time!

Download ISAPI_Rewrite and install it on your server. Then browse to the directory where you installed it, open httpd.conf file in Notepad, paste these lines into it and save it:

RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(index\.php)*(.*)$ index.php/$2 [NC,L]

Fire up IIS Manager, right-click on your WordPress blog website and select Properties. Click the ISAPI Filters tab and then the Add button. Under the Filter Name, give it a name of your choice, click the Browse button, browse to the directory where you installed ISAPI_Rewrite, and select ISAPI_Rewrite.dll file. Click Ok, then Ok again to close the Properties dialog, and… You are done!

If you have not set up your pretty permalinks yet, log in to wp-admin, click on Settings and then on Permalinks to set them up.

Regularly, everything should be working right after the steps above. If your permalinks are still not working, restart IIS by right-clicking on your server in IIS Manager and selecting All Tasks > Restart IIS.

Have fun!

This entry was posted in WordPress and tagged , , , , , , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *