How to Set Custom Error Pages Using Htacess

| Last Updated: | In: Code Snippets


If you want to design the custom error page for the server side error like 400, 401, 500, 502, and etc…, then keep your close attention in this as I am going to explain how to set custom error pages using Htacess file.

Open your htacess file from root directory of your website and copy paste below code at the end the file and save it. You can change the file name in the below code.

You can also create a folder in the root directory and keep all your errors page inside that folder. In this case, use the below code in htacess


About: Prem Tiwari

Prem Tiwari is the founder of freewebmentor.com and is a professional developer who has vast experience in PHP and open source technologies. Apart from this, he is a blogger by hobby and also he has been a regular speaker of WordPress sessions in various IT Companies.


You may also like:

Tags: , , , , , ,