Install and set up a website in IIS on Windows 10

If you want to learn more about web design and development, installing Internet Information Services (IIS) on a Windows 10 computer is an effective method. IIS is a free Windows feature included with Windows 10, so why not use it?

If you want to learn more about web design and development, installing Internet Information Services (IIS) on a Windows 10 computer is an effective method. IIS is a free Windows feature included with Windows 10, so why not use it?

There are 3 ways to install and set up websites in IIS on Windows 10; Use graphical user interface (GUI), PowerShell or Windows CMD.

Install IIS using the GUI

This is a simple method to set up websites in IIS. It might be the ideal method if you haven't learned PowerShell or Windows commands.

1. Start typing 'turn on windows' in the Search bar . The Turn Windows features on or off utility  will display. Click on it.

2. The Windows Features window will open. It may take some time for other features to load. When done, click the checkbox next to Internet Information Services , then click the OK button .

Picture 1 of Install and set up a website in IIS on Windows 10
Click the checkbox next to Internet Information Services

3. The installation will begin and may take several minutes. Once completed, click the Close button .

4. To make sure IIS is installed and working, enter IIS in the Search bar near the Start button . As a result, you will see Internet Information Services Manager . Click it to open.

5. When IIS Manager opens, look to the left of the window in the Connections section . Expand the tree menu until you see Default Web Site . It is a placeholder website installed with IIS. Click on it to select.

Picture 2 of Install and set up a website in IIS on Windows 10
Expand the tree menu until you see Default Web Site

6. On the right side of IIS Manager , see the Browse Website section . Click Browse *: 80 (http) . The default web page opens in the default web browser.

Picture 3 of Install and set up a website in IIS on Windows 10
Click Browse *: 80 (http)

7. You will see a website as follows. Note the address bar has content localhost. That is the address to enter the new website.

Picture 4 of Install and set up a website in IIS on Windows 10
Address to enter the new website

Create the first site for IIS

Before going into the other two methods of installing IIS, let's look at where the site creation files are stored. The article will also create a very basic website. When you learn how to do this, you will learn the basics for getting into web design and development.

1. After IIS is installed, open File Explorer. Navigate to C: intepubwwwroot. That is where the files that make up the website should be stored. You should see the default IIS website file, iisstart.html and the image displayed on the page, iisstart.png. This is where you will save your first web page.

Picture 5 of Install and set up a website in IIS on Windows 10
Navigate to C: intepubwwwroot

2. Open Notepad with admin rights. To save to the wwwroot location , you must be an administrator.

3. Save the file to the wwwroot location . Name it index.html and change Save as type: to All Files . Then click the Save button .

Picture 6 of Install and set up a website in IIS on Windows 10
Save the file to wwwroot location

4. Now that it has been saved as the correct filetype, let's add some content in it. Enter the following HTML code to get a very basic web page and save it:

Hello World!

5. Return to the web browser with the default IIS website. Click the Refresh button . You should now see your first webpage.

Install IIS using Windows commands

You can shorten the installation of IIS into a command line. It can be done in the Windows Command Prompt or using PowerShell.

1. Open Command Prompt with admin rights.

2. Enter the following command and press Enter:

DISM /online /enable-feature /featureName:IIS-DefaultDocument /All

3. You will see a progress bar appear. When it reaches 100.0% and you see the message 'The operation completed successfully' , you can close the Command Prompt. IIS has been installed.

Picture 7 of Install and set up a website in IIS on Windows 10
IIS has been installed

4. Verify that you can open IIS Manager and the installation is working, using steps 4 - 7 from the IIS settings section with the GUI section.

Install IIS with PowerShell

1. Run PowerShell ISE with admin rights.

Picture 8 of Install and set up a website in IIS on Windows 10
Run PowerShell ISE with admin rights

2. Enter the following cmdlet and run it:

Enable-WindowsOptionalFeature -Online -FeatureName IIS-WebServerRole -NoRestart

3. You will see a progress bar begin. Once completed, check to make sure IIS is installed and working.

This step is optional, but you can save it as a PowerShell script and then run it anytime. Let's work with the script and add different parameters. Finally, you will have an IIS installation script to set everything up exactly as you want it, which you can use anytime, with just one click.

Update 20 May 2020
Category

System

Mac OS X

Hardware

Game

Tech info

Technology

Science

Life

Application

Electric

Program

Mobile