.htaccess(hypertext access) files are distributed configuration files that allow to change the configuration of directory of most commonly web server Apache. .htaccess files can contain one or more configuration directives. A .htaccess file with directives enable the directives of that directory where you place the file and all sub directories, unless disabled in the main configuration. By using .htaccess file you can do following on your Apache based web server
- to protect your web directory with password
- to allow and deny user IP addresses
- to made custom directory index page
- to redirect HTTP request
- to make custom 404 error page
- to change your file extensions
- to stop directory listing
- to made SEO friendly URL of a website














