How to: Set Debug and Release Configurations

This topic applies to:






Web Developer


Topic applies Topic applies Topic applies Topic applies


Topic applies

Topic applies

Topic applies

Topic applies

Pro and Team

Topic applies Topic applies

Topic applies

Topic applies

Table legend:

Topic applies


Topic does not apply

Does not apply

Topic applies but command hidden by default

Command or commands hidden by default.

A Visual Studio project has separate configurations for Release and Debug versions of your program. As the names imply, you build the Debug version for debugging and the Release version for the final release distribution.

If you create your program in Visual Studio, Visual Studio automatically creates these configurations and sets appropriate default options and other settings. With the default settings:

  • The Debug configuration of your program is compiled with full symbolic debug information and no optimization. Optimization complicates debugging, because the relationship between source code and generated instructions is more complex.

  • The Release configuration of your program contains no symbolic debug information and is fully optimized. Debug information can be generated in PDB Files (C++) depending on the compiler options used. Creating PDB files can be very useful if you later need to debug your release version.

You can switch between Release and Debug versions by using the Standard toolbar or the Configuration Manager. For more information, see How to: Create and Edit Configurations.


When you set up Visual Studio, you are asked to choose a set of Development Settings for your primary programming language. If you choose the Visual Basic Development Settings, the tool for choosing the Debug or Release configuration does not appear in the toolbar. Instead, Visual Studio automatically chooses the Debug configuration when you choose Start from the Debug menu and the Release configurations when you use the Build menu. To change the Development Settings, see How to: Restore Hidden Debugger Commands. After you change the Development Settings, make sure that Show advanced build configurations is selected in the Options dialog box, Project and Solutions category, General page.

To switch to the Debug or Release configuration

  • On the Standard toolbar, choose either Debug or Release from the Solution Configurations list box.

Changing Settings

You can change the settings for a configuration by using the <Project>Property Pages. Depending on the project type, this window will either be a dialog box that contains a tree control on the left for navigating categories — Visual C++ and Web sites — or a tabbed window in the text editor pane of Visual Studio.

To change the settings for the Debug or Release configuration

  1. In Solution Explorer, select the project.

  2. On the View menu, click Property Pages. Or, you can right-click the project name in Solution Explorer, and select Property Pages.

  3. In the <Project> propertypage, select either the Debug tab or, if the project type is a Web site, Start Options.

  4. In the Configuration list box, click Debug or Release.

  5. Edit the value of the configuration settings you want to change. Not all debugger-related properties are contained in the Debug page; there are more on the Build page. The exact tabs that are displayed will vary by project type.

See Also


Project Settings for C# Debug Configurations

Project Settings for a Visual Basic Debug Configuration


Project Settings for a C++ Debug Configuration

Other Resources

Debug Settings and Preparation