The .htaccess file is a configuration file of the Apache Web server that allows the administrator to define additional folder access and addressing options. Such file uses the same syntax of the other Apache configuration files and it must be placed inside the folder of the Web server that has to be configurated.
The use of .htaccess files guarantees an high control granularity on folders-