Be careful about changing the .htaccess if you manage your website with WordPress

I had a customized .htaccess for my website so that all the old links could be 301-redirected to the new links once the website was fully ported to WordPress, and things worked great. I uploaded all the content, the .htaccess file, activated my theme, and changed the permalink structure to make the URLs SEO-friendly.

After a few days I was checking Google analytics, and noticed that some links that didn’t exist in the main navigation, but existed on the inner pages, were not being found, and needed to be redirected. I quickly added them to my .htaccess file and re-uploaded the file. After a few hours I noticed none of my pages worked. I remember this happening once, so I went to the permalinks section in the WordPress admin and again saved the permalinks setting. The links started working again.

Then today again I uploaded the .htaccess file and noticed that the website stopped working. Again I went to the permalinks section, saved the permalinks setting and the pages came back. Then it came to my mind that whenever you make changes to the permalinks structure, WordPress changes your .htaccess file. So whenever I was uploading my version of .htaccess, the changes were being overwritten, and the pages refused to work. Dumb of me actually.

So now after saving the permalinks settings I have downloaded .htaccess. Whatever changes I have to make, I’ll make in this file, without overwriting the WordPress settings for handling permalinks. Small oversights can cost you big time sometimes!

This entry was posted in About Work, Business Development by .

About Amrit Hallan

Amrit Hallan is a professional content writer who helps businesses improve their conversion rate through credible and compelling content writing. His main strength lies in writing search engine optimized content without compromizing quality and meaningfulness.

One thought on “Be careful about changing the .htaccess if you manage your website with WordPress

  1. Youxiang

    What kind of shoes to wear in winter? In a word, fashion and warm comfort. Uggs will be the apple of every fashionistas’ eyes, which has been identified as a fashion trend for men and women. People also want to buy discount ugg boots for subsequent commands quickly. Our online shop http://www.ugg-in.com supplies for many kinds of comfortable beautiful women's ugg sale boots. You will enjoy toasty warm comfort and maximum versatility in the UGG Classic Cardy boot. We promise uggs sale at a big discount is with high quality. The more you buy here, the more discount you will enjoy.

Leave a Reply