Skip to main content
To install IIS on Windows Server, open PowerShell as administrator and run Install-WindowsFeature -Name Web-Server -IncludeManagementTools, or add the Web Server (IIS) role in Server Manager > Manage > Add Roles and Features. IIS starts straight away and serves its default page from C:\inetpub\wwwroot on port 80. Allow ports 80 and 443 in Windows Firewall, then add your own site in IIS Manager (inetmgr).

Before you start

  • Sign in as an administrator with Remote Desktop.
  • If you want to use a domain such as example.com, create an A record pointing to your server’s IP (for example 203.0.113.10) at your DNS provider now, so it has time to spread.
  • IIS (Internet Information Services) is Microsoft’s web server. It is a Windows role, so it comes with Windows Server and needs no separate download.

How to install IIS with PowerShell

Open PowerShell as administrator: select Start, type PowerShell, right-click Windows PowerShell and choose Run as administrator.
1

Install the Web Server role

-IncludeManagementTools adds IIS Manager. Without it you get the web server only (Microsoft Learn).
2

Check the result

The output shows Success : True. If Restart Needed is Yes, run Restart-Computer.
3

Add extra role services (optional)

List what’s available, for example ASP.NET, CGI (for PHP) or FTP:
Install the ones you need by the value in their Name column, for example Install-WindowsFeature -Name <Name>.

How to install IIS with Server Manager

1

Open the wizard

In Server Manager, select Manage > Add Roles and Features.
2

Choose the installation type

Select Next, choose Role-based or feature-based installation, select Next, and keep your server selected.
3

Select Web Server (IIS)

On Server Roles, tick Web Server (IIS). Select Add Features when asked, then Next.
4

Install

Select Next through the pages to accept the default web server settings, then Install. When it finishes, select Close (Microsoft Learn).
Details about every page of the wizard are in install roles and features.

How to open the firewall for your website

Allow HTTP and HTTPS in Windows Defender Firewall. Adding these rules is safe even if setup already allowed port 80:
If you filter traffic in the Firewall panel, allow TCP 80 and 443 there as well. More on rules in open a port in Windows Firewall.

How to check IIS works

On your own computer, browse to http://203.0.113.10 (your server’s IP). You should see the IIS default welcome page. On the server itself:
StatusCode 200 means IIS is answering.

How to add your own website

The default site lives in C:\inetpub\wwwroot. For a real site, create its own folder and site so you can add more sites later.
1

Create the folder

Create C:\inetpub\example.com and copy your site files (with an index.html or default.htm) into it.
2

Open IIS Manager

Select Start, type inetmgr and press Enter.
3

Add the site

In Connections, expand your server, right-click Sites and choose Add Web Site (shown as Add Website in some versions).
4

Fill in the details

Site name: example.com. Physical path: C:\inetpub\example.com. Binding: type http, IP address All Unassigned, port 80, Host name example.com. Tick Start Web site immediately and select OK (Microsoft Learn).
5

Add www (optional)

Select the site, choose Bindings in the right-hand Actions pane, then Add a second http binding with host name www.example.com.
Browse to http://example.com. Because the binding has a host name, IIS serves this site for that name and the default site for anything else.

Next step: HTTPS

Get a free Let’s Encrypt certificate and HTTPS binding with win-acme: see free SSL certificate on IIS with win-acme.

Frequently asked questions

Can I run PHP on IIS?

Yes. Install the CGI role service (find its name with Get-WindowsFeature -Name Web-*) and then PHP for Windows. Follow PHP’s own Windows installation guide for the version you need.

Why do I see the IIS welcome page instead of my site?

You’re browsing by IP address or the host name doesn’t match your binding. Browse to the exact host name in the binding, check your DNS A record, and make sure your site is Started in IIS Manager.

How do I stop or remove IIS?

To take one site offline, select it in IIS Manager and choose Stop in the Actions pane. To remove it, run Uninstall-WindowsFeature -Name Web-Server -IncludeManagementTools and restart. Removing IIS takes all sites on the server offline.

VPS and dedicated server guides

Every guide in this section.

Free SSL on IIS with win-acme

Add HTTPS to your site.

Install roles and features

The full wizard explained.

Open a port in Windows Firewall

Inbound rules explained.

Install SQL Server Express

A database for your site.

Checked against Microsoft Learn: Install-WindowsFeature, Install the Web Server, Create a Web Site and New-IISSite on 4 November 2026. Not tested on a live Windows server for this page.

Need Extra Help?

If you encounter any issues, our support team is ready to assist:

Save on Your Hosting

Ready to upgrade your hosting? Use code KB20 at checkout for 20% off your first order!

Last Updated: November 2026