Instead of paying for web hosting, you can run your own web server on your own cable or DSL line on your home computer. Since many ISPs do not offer static IP addresses or charge extra, you can setup dynamic DNS through DynDNS to achieve the same result. You can then give your friends or anyone else the hostname and they should always be able to access your website.
Most people use Windows for an operating system but that doesn't mean you cannot run an industrial strength webserver, Apache. Apache is the most installed and popular web server and there is a lot of help out there if you get stuck.
Once you install your web server, you can host your own web site, host your MP3 files, allow friends and co-workers to view documents, share pictures, and plenty of other things.
DynDNS offers two flavors of dynamic DNS. One is Dynamic DNS (clever name) and the other is Custom DNS. Dynamic DNS allows you have a hostname like yourname.dyndns.org always point to your IP address. Custom DNS allows you to setup a domain, like www.yourname.com to point to your IP address. Custom DNS is a paid service and Dynamic DNS is free. Setup is pretty easy and you can use our Custom DNS How-To or our Dynamic DNS How-To.
Once dynamic DNS is setup, we know the hostname of our web site. Where we use yourhost.dyndns.org, replace that with the actual host you created.
Installing the server
Network Domain (e.g somenet.com): dyndns.org
Server Name (e.g. www.somenet.com): yourhost.dyndns.org
Administrator's Email Address (e.g. webmaster@somenet.com): youremailaddress
Storing files in the right place
Let's say you have a slew of pictures from your vacation and you want to share them on your shiny new web server. I store my pictures in C:\RecentPics so I'll use that in this sample.
Configuration
Using a plain text editor like Notepad, open the C:\Program Files\Apache Group\Apache2\conf\httpd.conf file. This is Apache's configuration file. Don't be alarmed. It looks worse than it is and we are only going to change a couple things and leave the rest as their defaults.
In this httpd.conf file, comment out the line that starts with DocumentRoot and add another with your directory, like this:
#DocumentRoot "C:/Program Files/Apache Group/Apache2/htdocs" DocumentRoot "C:/RecentPics"
Then, comment out the line that starts with <Directory "C:/Program...> and add another with the directory you want to share:
#<Directory "C:/Program Files/Apache Group/Apache2/htdocs"> <Directory "C:/ RecentPics">
Last, about 20 lines below that <Directory> line, then modify that to read (this allows file listing):
#AllowOverride None AllowOverride All
When you're done, save httpd.conf.
Start it up
Click on the Apache icon in your taskbar and choose "Restart." If Apache restarts successfully, you edited your the file correctly. Visit http://localhost/ in your web browser and you should see a list of your pictures!
If you can not connect to your server using the addresses above, you need to check the following:
yourhost.dyndns.org is pointing to the external IP, the one your ISP has assigned you. If not, log in and update it. You won't be able to access the host from inside your network if you are behind a router.