Chapter 19

Deploying Your Website

What You Will Learn in This Chapter:

  • How to ease the deployment process through simple changes to your code and configuration
  • How to prepare your site for deployment by creating a copy using Visual Studio's built-in copy tools
  • How to install and configure a web server and your website on your target machine
  • How to avoid common errors you may get when deploying a site
  • How to copy data stored in your SQL Server database to the target server Code Downloads for this Chapter

You can find the code downloads for this chapter on the Download Code tab at The code is in the Chapter 19 download.

Congratulations! The fact that you're reading this chapter probably means you now have a full-featured, database-driven ASP.NET website that is ready for release into the wild. It's an exciting time for you and your project. Pretty soon your application will be used and judged by your target audience.

To make your website accessible to users worldwide, you need to publish it to a production server that is connected to the Internet. What kind of server this is and where it is located depends on your own requirements and budget. You can host the site on a home server in your attic with a private Internet connection (as I used to do with or you can host it with an external (and often commercial) party with a direct connection to the Internet backbone.

Either way, you need to do ...

Get Beginning ASP.NET 4.5: in C# and VB now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.