How to Install Dev C++ and Configure the Compiler on Windows 11
Learn c++ programming from scratch with our free, beginner-friendly tutorials. Access open-source content, download PDF lessons, and start coding today!.
I can guide you step by step on installing Dev C++ on Windows 11 and configuring the compiler so you can run C++ programs smoothly. Let's go through it carefully.
Step 1: Download Dev C++
- Go to the official Dev C++ website: https://sourceforge.net/projects/orwelldevcpp/
- Click Download. You’ll get an
.exeinstaller (usually named something likeDev-Cpp-2022.exe).
⚠️ Make sure to download the latest version, which comes with the GCC compiler built-in. This avoids separate compiler configuration.
Step 2: Install Dev C++
-
Run the downloaded
.exefile. -
Follow the installation wizard:
- Click Next on welcome screen.
- Choose installation location (default is fine, e.g.,
C:\Program Files\Dev-Cpp). - Click Next and Install.
-
Wait for the installation to complete and click Finish.
Step 3: Launch Dev C++
- Open Dev C++ from Start Menu or desktop shortcut.
- You should see the main IDE window.
Step 4: Configure the Compiler (if needed)
Newer Dev C++ versions usually include MinGW GCC compiler. But if your installation doesn’t detect the compiler:
-
Go to Tools → Compiler Options → Compiler Settings → Executables.
-
Check the Compiler's installation directory path:
- Default:
C:\Program Files\Dev-Cpp\MinGW64(or similar).
- Default:
-
Make sure the following executables exist in
binfolder inside the compiler directory:gcc.exeg++.exegdb.exe(optional for debugging)
-
If not, you may need to download MinGW separately and set the path.
Step 5: Test the Compiler
- Open Dev C++ → File → New → Source File.
- Write a simple program:
#include <iostream>
using namespace std;
int main() {
cout << "Hello, World!" << endl;
return 0;
}- Save the file as
hello.cpp. - Click Execute → Compile & Run (or press
F11). - You should see a console window displaying:
Hello, World!
✅ If this works, your Dev C++ installation and compiler are properly configured.
Optional Step 6: Set Environment Variable (for command-line use)
If you want to compile programs using Command Prompt:
-
Add the path to the
binfolder of your MinGW compiler to Windows PATH:- Right-click This PC → Properties → Advanced system settings → Environment Variables → Path → Edit → New → Paste path to bin.
- Example:
C:\Program Files\Dev-Cpp\MinGW64\bin
-
Open Command Prompt and type:
g++ --versionYou should see the GCC version.