Setting Up Visual Studio for Unreal Engine

Tips, tricks, and techniques for setting up Visual Studio to work with Unreal Engine 4.


Unreal Engine is designed to integrate smoothly with Visual Studio, allowing you to quickly and easily make code changes in your projects to immediately see results upon compilation. Setting up Visual Studio to work with Unreal Engine can help improve efficiency and the overall user experience for developers using Unreal Engine.

In this document, we'll also cover the basics for setting up your Unreal Engine-to-Visual Studio workflow.

Before Setting-up your Unreal Engine-to-Visual Studio Workflow

In Visual Studio 2017 (VS2017), support for C++ is now part of optional workloads that aren't installed by default. For detailed instructions on adding C++ tools to your existing Visual Studio installation, see Install C++ support in Visual Studio on the Microsoft support page. If you have not yet installed Visual Studio or the Unreal Engine, see the Options for a New Visual Studio Installation section on this page.

The following table lists which versions of Visual Studio are integrated with the binary version of Unreal Engine.

Unreal Engine Version

Visual Studio Version

4.22 or Later

VS 2017

4.15 or Later

VS 2017

4.10 to 4.14

VS 2015

4.2 to 4.9

VS 2013

As of version 4.22, Unreal Engine does not support VS 2015. Unreal Engine still uses VS 2017 by default, but also supports VS 2019.

As of version 4.20, Unreal Engine uses VS 2017 by default. However, VS2015 is still supported. If you have VS 2015 installed but not VS 2017, Unreal Engine 4.20 will still work. However, if you have both VS 2015 and VS 2017 installed, Unreal Engine 4.20 will use the VS 2017 IDE and compiler by default, as well as generating VS 2017 project files.

To configure Unreal Engine 4.20 to generate a VS 2015 solution and project files, you can do either of the following:

  • Select the version of Visual Studio you wish to use as your preferred source code IDE in the editor (from the editor preferences window)

  • Modify the relevant section of the BuildConfiguration.xml file

Open source versions of Unreal Engine (available through GitHub and Perforce) are integrated with VS2013. Also, earlier versions of Unreal Engine integrated with older versions of Visual Studio aren't covered in this document.

Run the Unreal Engine Pre-Requisite Installer

When you install Unreal Engine from the Epic Launcher, or if you clone it from GitHub, the Unreal Engine pre-requisite installer runs automatically. However if you install or sync Unreal Engine from Perforce, you will need to manually run the pre-requisite installer. You need to do that before running any Unreal Engine tools you have built locally.

Options for a New Visual Studio Installation

If you're installing Visual Studio for the first time, you'll want to make sure that you have the following options enabled.

C++ Tools

To add C++ tools to your Visual Studio installation, make sure you select Game development with C++ under Workloads.


Include the UE4 Installer

To include the UE4 installer when installing Visual Studio, locate the Summary sidebar on the right, expand Game Development with C++, and under Optional make sure the box for Unreal Engine installer is checked.


Recommended Settings

The following are recommended settings for developers using Visual Studio with Unreal Engine 4.

Increase the Width of Solution Configurations Dropdown Menu

  1. Right-click on the toolbar and select Customize at the bottom of the menu that appears.

  2. Click on the Commands tab.

  3. Select the Toolbar radio button.

  4. In the dropdown next to Toolbar, choose Standard.

  5. In the Preview list, select the Solution Configurations control.

  6. Click Modify Selection on the right.

  7. Set the Width to 200. Then click OK.

  8. Click Close. Your toolbar should update immediately.

Add the Solution Platforms Dropdown

  1. Locate the right-most button on the Standard toolbar (if you hover the mouse over it, it’s labeled Standard Toolbar Options). SetUpVisualStudio-RecommendSettings-SolutionPlatformsStep01.png

  2. Click the dropdown button, click Add or Remove Buttons, and then click on Solution Platforms to add the menu to the toolbar.


Turn Off the Error List Window

Typically, the Error List window pops up automatically when you have an error in your code. However, when working with Unreal Engine, the Error List window can display false error information. It's best to disable the Error List window, and use the Output window to see real code errors when working with Unreal Engine. The following steps show you how to turn off the Error List window.

  1. Close the Error List window if it is open.

  2. From the Tools menu, open the Options dialog.

  3. Select Projects and Solutions and uncheck Always show Error List if build finishes with error.

  4. Click OK.

Here are some other configuration settings you may find useful:

  • Turn off Show Inactive Blocks. If you don't, many chunks of code may appear grayed out in the text editor. Go to Tools > Options > Text Editor > C/C++ > View to turn off this setting

  • Set Disable External Dependencies Folders to True to hide unneeded folders in the Solution Explorer. Find Disable External Dependencies Folder in Tools > Options > Text Editor > C/C++ > Advanced.

  • Turn off Edit & Continue features, you do not need them.  Go to Tools > Options > Debugging > Edit and Continue.

  • Turn on IntelliSense. See the Intellisense, Live Errors, and Squiggles section on this page.

Visual Assist X Users

If you have Visual Assist X installed:

  • Turn off Format After Paste. Go to VAssistX > Visual Assist X Options > Advanced > Corrections to change this setting.

  • If you don't disable this option, Visual Assist X formats your source code automatically. This can result in poorly formatted documents.

Intellisense, Live Errors, and Squiggles

UE4 projects now have proper IntelliSense support, including a live Error List and squiggles. See below for how to enable it.

IntelliSense recompiles C++ as you type. This is a lot more powerful than VAX's syntax checking, as it uses a full C++ compiler that verifies every line of code. This will speed up your workflow dramatically.

VC++ Intellisense Squiggles

Along with squiggles, you will also see IntelliSense errors in the Error List for any file you are looking at. You can turn this on or off in the right-click menu in the Error List.

Error List

You may have already disabled squiggles because they didn't work with UE4 projects. Make sure to click C/C++ > Advanced and use settings similar to the ones shown below.

VC++ Advanced Options

When you open a C++ file, the icon shown below indicates that the IntelliSense compiler is working.

Intellisense Progress Indicator

Implementation Details

  • It sometimes takes a few seconds for squiggles to appear when you edit code. This is because we have a lot of include files, and IntelliSense does not use PCHs currently.

  • Sometimes you will see "false positive" IntelliSense errors. There are a few possible reasons.

    • The IntelliSense compiler (EDG) is more strict than the MSVC compiler.

    • Some #defines are set up differently for IntelliSense than they are set up for building normally.

    • C++ compiled by IntelliSense is always treated as 32-bit.

  • You can wrap code in #ifdef **INTELLISENSE** to eliminate squiggles if absolutely necessary.

  • The IntelliSense errors are phrased a bit differently than the VC++ compiler's errors.

  • Squiggles in header files work by compiling the header against a known .cpp that includes it. Sometimes IntelliSense screws this up and you will see squiggles in headers.

  • There is a Max Cached Translation Units setting that you can increase if you want to increase responsiveness. It uses more memory, however.

  • A few C++ files are not compatible with IntelliSense yet.

  • Unreal Build Tool has a new -IntelliSense option.

    • This option will generate IntelliSense property sheets for all of our project files.

    • This option only needs to be re-run when new modules are added, or project includes are changed.

UnrealVS Extension

The UnrealVS extension for Visual Studio provides easy access to common actions when developing with Unreal Engine 4. This document will explain how to install the extension, as well as how to use it with your project.

Features include:

  • Setting the Startup Project.

  • Bindable command for building the Startup Project.

  • Setting the command line arguments.

  • Batch building projects.

  • Quick Build project menu.

The UnrealVS extension does not work with the Visual Studio Express editions. It is only compatible with Visual Studio Community and Professional editions.


Visual Studio has support for extending the debugger with visualizers that allow easy inspection of common Unreal types such as FNames and dynamic arrays.

Installing the UE4 Visualizer for Visual Studio 2013

Copy UE4.natvis to either of the following locations:

  • [VisualStudioInstallPath]/Common7/Packages/Debugger/Visualizers/UE4.natvis

  • [UserProfile]/My Documents/Visual Studio 2013/Visualizers/UE4.natvis

Copying the file to your Visual Studio install directory may require administrator permissions.

Выбрать тему

Добро пожаловать на новый сайт документации Unreal Engine 4!

Мы работаем над множеством новых функций, включая систему обратной связи, чтобы вы могли рассказать нам, о том, что мы делаем. Этот вариант не совсем готов для использования в конечном релизе, поэтому перейдите на форум обратной связи по документации, чтобы рассказать нам о проблемах с этой страницей или написать нам о любых проблемах, с которыми вы сталкиваетесь в работе с документацией.

Мы обязательно сообщим вам, когда новая система будет запущена.

Отправить отзыв