Setting up IIS on Windows Server
1. Installing IIS
- Open Server Manager.
- Click Add Roles and Features.
- Select Role-based or feature-based installation.
- Check Web Server (IIS).
- Add recommended features and finish installation.
2. Testing IIS
- Open your browser and type
http://localhost. - If the IIS default page appears, it’s working.
3. Creating a Website
- Open IIS Manager (type
inetmgrin Run). - Right-click Sites → Add Website.
- Fill in:
- Site name: Your site’s name.
- Physical path: Folder with your files (e.g.
C:\inetpub\wwwroot\mysite). - Binding: IP, port (usually 80), and domain (if any).
- Click OK.
4. Testing the Site
- Access
http://localhostor your server’s IP. - If using a domain, point DNS to the server’s public IP.
5. Setting Permissions
- Go to your site folder.
- Right-click → Properties → Security.
- Add IUSR user and grant Read (or Modify if needed).
6. Enabling HTTPS (SSL)
- In IIS Manager, open Bindings for the site.
- Add https on port 443.
- Select the installed SSL certificate (Let’s Encrypt or other).
7. IIS Logs
Logs are stored at C:\inetpub\logs\LogFiles. Useful for debugging errors.