Using Emulator Express to run and debug an Azure cloud service on a local machine

Note

This article applies to Azure Cloud Services (classic), which is now deprecated for new customers and will be retired on August 31, 2024. Existing services built with this technology are still supported through Azure Cloud Services (extended support). For new development, we recommend that you use a newer service type designed for your specific purpose, such as Azure App Service, Azure Functions, or Azure Container Apps. For the latest list of available services, see Directory of Azure products.

By using Emulator Express, you can test and debug a cloud service without running Visual Studio as an administrator. You can set your project settings to use either Emulator Express or the full emulator, depending on the requirements of your cloud service. For more information about the full emulator, see Run an Azure Application in the Compute Emulator.

Using Emulator Express in Visual Studio

When you create an Azure project, Emulator Express is automatically used. For existing projects that were created with an earlier version of the Azure SDK, use the following steps to select Emulator Express:

  1. Create or open an Azure cloud service project in Visual Studio.

  2. In Solution Explorer, right-click the project, and, from the context menu, select Properties.

  3. In the projects properties pages, select the Web tab.

    Properties for an Azure cloud service project

  4. Under Local Development Server, select Use IIS Express option.

  5. Under Emulator, select Use Emulator Express.

  6. To launch the Emulator Express, run the following command at a command prompt:

    csrun.exe /useemulatorexpress

Emulator Express limitations

The following issues are known limitations of Emulator Express:

  • Emulator Express is not compatible with IIS Web Server.
  • Your cloud service can contain multiple roles, but each role is limited to one instance.
  • You can't access port numbers below 1000. If you use an authentication provider that normally uses a port below 1000, you might need to change this value to a port number that's above 1000.
  • Any limitations that apply to the Azure Compute Emulator also apply to Emulator Express. For example, you can't have more than 50 role instances per deployment. For more information about the Azure Compute Emulator, see Run an Azure Application in the Compute Emulator.

Debugging Azure Cloud Services