Migrating IIS Sites Using Web Deploy
Last updated
Was this helpful?
Last updated
Was this helpful?
Web Deploy can migrate:
IIS site configuration
Application Pools
Content (HTML, ASP.NET, etc.)
Web.config files
SSL certificates
Databases (SQL Server)
Permissions and ACLs
Download Web Deploy:
Visit the .
Choose the appropriate version of Web Deploy for your operating system and click “Download.”
Install Web Deploy:
Run the downloaded installer with administrative privileges (right-click and choose “Run as administrator”).
Follow the installation wizard:
Accept the license terms.
Choose the installation location (you can leave it as the default).
Select the components to install. Make sure to select at least the following:
Web Deployment Tool
IIS Deployment Handler
Management Service Delegation UI
Click “Install” to begin the installation.
Open IIS Manager:
Press Win + R
, type inetmgr
, and press Enter to open the Internet Information Services (IIS) Manager.
Enable Management Service:
In IIS Manager, select your server node (usually the top node in the Connections pane on the left).
Double-Click on “Management Service” under the “Management” section in the middle pane.
Configure Management Service:
Check the “Enable remote connections” checkbox to allow remote management of the IIS server.
Set the “Start Type” to “Automatic” to ensure the service starts automatically with Windows.
Specify a unique port for the management service (default is 8172).
You can also configure other settings like SSL and client certificates if needed.
Configure Permissions:
Under “Management Service Delegation,” you can configure permissions for various users and roles. Click “Add User…” to specify the users or groups that should have permission to deploy websites.
Apply Changes:
Click the “Apply” button to save your configuration.
Now that Web Deploy is installed and IIS is configured, you can use Web Deploy to export and import websites with application pools.
Open a Command Prompt:
Press Win + X
and choose “Command Prompt (Admin)” to open a command prompt with administrative privileges.
Run the Export Command:
Use the msdeploy
command to export a website. Replace placeholders with actual values:
<ServerName>
: Replace with the server name or IP address.
<Username>
and <Password>
: Replace with the credentials of an account with sufficient permissions.
<PathToPackage.zip>
: Specify the path where you want to save the exported package.
Open a Command Prompt:
Open a command prompt with administrative privileges.
Run the Import Command:
Use the msdeploy
command to import a website. Replace placeholders with actual values:
<PathToPackage.zip>
: Specify the path to the package you want to import.
<ServerName>
: Replace with the server name or IP address.
<Username>
and <Password>
: Replace with the credentials of an account with sufficient permissions.
Execute the Command:
Execute the command, and the website with its associated application pool will be imported to the target server.
Sync full site (directly):
List available sites on a server:
Sync only the content folder: