Magnus Rahl
Nov 4, 2010
visibility 9811
star star star star star
(0 votes)

Running EPiServer CMS in IIS Express

Introducing IIS Express

This summer Microsoft released their WebMatrix platform. WebMatrix is intended as a getting started-kit for web development, containing SQL Server Express, Visual Web Developer Express, a number of example projects and snippets (and online access to more) and a web server: IIS Express.

IIS Express is built on the same core as IIS 7 but is designed to run in a stand-alone process in the current user’s context. This gives developers some new options:

  • Devs still stuck with Windows XP or Server 2003 can get an IIS 7 compatible web server running on their machines.
  • If you don’t want to run your sites in the local IIS when debugging from Visual Studio, you should be able to use IIS Express rather than the ASP.NET Development server and get the full IIS 7 feature set.

For more information on IIS Express, check out Scott Gu’s blog post

The Scenario

The reason I started exploring IIS express was that I wanted to run a dev/test site at home, on my home server. That machine is currently running Windows XP while my dev laptop is Windows 7. To avoid the hassle of double config sections I wanted to run IIS 7 on both machines. IIS Express fixes this.

Installing IIS Express

As mentioned, IIS Express is part of the WebMatrix bundle. So you have to download the WebMatrix installer, but you can then customize the install to include only the parts you need. IIS Express is part of the base set so at first I was trying to find it among the install options but I didn’t. It seems it’s always installed, but you don’t have to install Visual Web Developer etc. unless you want to.

Setting up a site in IIS Express

You can’t use EPiServer Deployment Center to install a site in IIS Express since it’s not run as a service. So there’s no (easy) way to install a new site on the machine running IIS Express.

When launching WebMatrix there is instead an option to create a site from a folder. So if you have installed the EPiServer site on another machine (in my case the dev laptop) you can just publish your solution to a folder and create a site from it in WebMatrix.

Running sites in IIS Express

WebMatrix is then the launch pad for your sites where you set their URL, port and start/stop the sites. It is however possible to launch IIS Express from a command prompt. It’s located in your Progam Files folder under Microsoft Web Matrix and is called iisexpress.exe.

Your site definitions will be stored in an xml file called applicationhost.config in a folder called IISExpress under the current user accounts Documents folder. This file will be used when launching iisexpress.exe and the first site defined (it seems) will be launched.

Using switches it is possible to set what site should be started and even which .config file should be used. So you can store the applicationhost.config in a central location away from the user settings folder if you like:

iisexpress /config:c:\myconfig\applicationhost.config /site:Website1

You can even start a site directly from the folder where it’s stored:

iisexpress /path:c:\myapp\ /port:80

Hosting a site using IIS Express

IIS isn’t intended for hosting. But since it can be started as a console app there’s at least a possibility to start it as a scheduled task when the computer starts up or to run it as a windows service using a generic host. But will it work? Out of curiosity I had to try and yes it will! With some limitations of course.

One limitation is that there is no way to set multiple host headers (at least not that I can find). The site is configured to run under a host/port combination, default to localhost/machine name and port 8080. Set it to use your external domain name and port 80 and it’s ready to go.

I did some basic testing using the free test on LoadImpact. There seems to be no connection limit, at least not up to the 50 connections that the free test uses. It seems to scale rather well in this connection count span, even with my rather weak hardware.

Nov 04, 2010

Comments

Jeff Wallace
Jeff Wallace Nov 4, 2010 04:39 PM

Nice write up. :)

error Please login to comment.
Latest blogs
Add more scheduled job settings from the Optimizely CMS 12 admin UI -- with OptiScheduledJob.ExtraParameters

  Optimizely (EPiServer) CMS 12 ships a great scheduled-jobs framework, but it has one frustrating gap: a job has nowhere to store its own...

Binh Nguyen Thi | Jun 25, 2026

Automated Search & Navigation to Graph Migration with Claude Code

A Claude Code plugin that scans your S&N codebase, applies Graph SDK transformations, and validates the result. Install once, run one command. CMS ...

Connor Fortin | Jun 24, 2026

Migrating from Find to Graph: Lessons Learned from a Real CMS 13 Project

While migrating a search solution from Optimizely Search & Navigation (Find) to Optimizely Graph in CMS 13, I encountered several issues that were...

Binh Nguyen Thi | Jun 24, 2026

Optimizely: Upgrade Opti-ID and .NET 10 in CMS 12

Many Optimizely customers are planning their roadmap around a future migration to Optimizely CMS 13. As a result, upgrades such as Opti ID adoption...

Madhu | Jun 23, 2026 |

Understanding Optimizely Graph: Caching, Webhooks & Avoiding Stale Content (Optimizely SaaS CMS)

📌 Scope: This post covers Optimizely CMS (SaaS) only — using the official @optimizely/cms-sdk and @optimizely/cms-cli packages with Next.js 15. If...

Kiran Patil | Jun 23, 2026 |

Optimizely Content APIs: the Setup the Docs Don't Walk You Through

CMS 13 is pushing things firmly in the direction of Optimizely Graph, but plenty of teams are still running on older CMS versions, or have good...

Andre | Jun 22, 2026