If you have using some CMS that has not a module to manage taking a web site offline, then you can do that in a easy way using mod_rewrite rules.
Just backup your old .htaccess and add this lines in you .htaccess on the begining :
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_URI} !^/offline\.php$
RewriteRule ^(.*)$ /offline\.php [L]
Make a web page with the name offline.php with information about why your site is offline (be nice to your visitors) and upload to the root of your document directory.