How to Set Custom Permalinks in Local WordPress Installation

How to Set Custom Permalinks in Local WordPress Installation

Setting up a local server environment is always good for bloggers; especially you are using WordPress as your CMS. You can use WAMP, XAMPP or MAMP for setting up a PHP and MySQL powered server environment in your PC and install WordPress in it, just as you do it in your server. It can give you a good experience and works as a testing place for your code based works.

How to Set Custom Permalinks in Local WordPress

One of the problems we have found when using such a Local WordPress installation is that, they are not able to reset the permalink structures. If you are trying to change your default permalink structure, it will not work and will show a “Page Not Found” error in the screen. However, this problem is resolvable by applying a small feature in the local server itself. We provided two methods, you can try any method of your wish.

First Method: Re-writing a Module

First Step

What we are going to do is just re-writing a module. This feature is available in WAMP, XAMPP or MAMP. We are doing it here via WAMP. Start WAMP Server and find the WAMP icon in the taskbar. Click on the icon and a menu will appear near to the icon. You can see an option called Apache and Apache Modules as a sub option of Apache.

Local Server WP Permalink Problem Solution Step First

Second Step

Hover on the option ‘Apache Modules’. You can see a list of modules installed in the server including one named rewrite_module. By default, rewrite_module is not active. What do you want to is just enabling that option.

Local Server WP Permalink Problem Solution Step Second

Third Step

Just try changing the permalink structure from WordPress dashboard. It would work properly.

SEE ALSO: How to Create Sub-Domains Using XAMPP.

Second Method: Editing httpd.conf File

Step One

Go to the WAMP server folder in C drive -> Apache -> There you can see a file named httpd.conf. Select your favorite editor and open the file in it.

Step Two

Find the following line

 #LoadModule rewrite_module modules/mod_rewrite.so

Replace it by

LoadModule rewrite_module modules/mod_rewrite.so

You are done. Now you can change the default permalink structure of your local WordPress installation. Everything will be work as per your expectations.


Join Our Email Newsletter

Like what you read here in this blog post? Get free blog updates in your Email!

About Abhijith N Arjunan

Abhijith N Arjunan is a passionate writer and blogger from Kerala, who finds ultimate joy when writing about trending technology, geek stuff and web development.

Abhijith N has written 40 awesome articles for us at TechLila.

Find Abhijith N on: Google Profile

Comments

  1. Mindy Stevens says

    I am so happy I found your article. I kept getting a Page Not Found error. With your step-by-step instructions, I fixed the problem quickly. Thank you.

 Comment Policy

Your words are your own, so be nice and helpful if you can. Please, only use your REAL NAME, not your business name or keywords. Using business name or keywords instead of your real name will lead to the comment being deleted. Anonymous commenting is not allowed either. Limit the amount of links submitted in your comment. We accept clean XHTML in comments, but don't overdo it please. You can wrap code in [lang-name][/lang-name] tags.


Tell us what you're thinking...

If you want a picture to show with your comment, then get Gravatar!

CommentLuv badge