For Windows 11, the recommended way to install MinGW-w64 GCC is through MSYS2. MSYS2 provides native Windows compiler builds, mingw-w64 libraries, and the pacman package manager used to install and update them.
This guide uses the current UCRT64 environment. Older tutorials may use MINGW64 and mingw-w64-x86_64-gcc; those instructions target the older MSVCRT-based environment and are not the best default for a new Windows 11 installation.
Before you begin
MSYS2 requires 64-bit Windows 10 version 1809 or newer, so a supported Windows 11 installation meets the host requirement. The GCC package itself is approximately 48.87 MB to download and 254.50 MB installed, before dependencies; package details can change. See the current GCC package listing.
| Requirement | Recommendation |
|---|---|
| Windows version | 64-bit Windows 11 |
| Installation method | MSYS2 installer followed by pacman |
| Compiler environment | MSYS2 UCRT64 |
| Install location | C:\msys64, or another short ASCII-only NTFS path |
| Compiler package | mingw-w64-ucrt-x86_64-gcc |
1. Download the correct MSYS2 installer
Open msys2.org and find the Installation section. Select the installer that matches your Windows processor:
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
#1 Best Overall
- 【Premium Performance】Dual-USB Charger output cell phone charger with a total current of 5V/2.4A and input with 110-130V,It can simultaneously charge two mobile devices, allowing you to save more time
- 【Safe Charging】USB Wall Charger is made of PC fireproof material and is equipped with multiple protections, such as output short circuit protection and built-in over-current, over-voltage, and over-heating protection. The USB Charge adapter has undergone rigorous testing to ensure a longer service life and safer charging. And the phone charger block also features an automatic stop charging function when the battery is full
- 【Specifically Designed】Cell phone charger features a heat-resistant and anti-throw design. The wall charger block is compact, easy to carry, and has a comfortable grip. This usb charger block is suitable for use at home, while traveling, in the office, and on business trips. This charger features a dual port design that provides the most efficient current distribution for your two charging devices. Its USB charger port is manufactured with integrated injection molding technology, making it more robust and reliable.
- 【What You Will Get】3 Packs of 2-Port Rapid Charger (White), If you encounter any problems while using the USB wall charger, please feel free to contact our professional customer service team, Our team is dedicated to delivering a service that is not only professional, but also friendly and approachable.
- 【Search These KeyWords】Dual-USB Charger、USB Wall Charger、Dual Port charger、cell phone charger、USB charger port、wall charger block、usb A charger block、wall plugs with usb ports、phone charger block、usb cube
- Intel or AMD 64-bit: msys2-x86_64-20260611.exe
- Windows ARM64: msys2-arm64-20260611.exe
The filename is an installer release identifier, not the GCC version. MSYS2 package versions are updated separately through pacman.
If Windows Defender SmartScreen displays a warning, verify that you downloaded the installer from the official MSYS2 site. For a new or less frequently downloaded release, SmartScreen may show an “unrecognized app” message. The documented way to continue is to click More info, then Run anyway.
Optional: verify the installer signature
For a higher-confidence download, verify the installer signature using GnuPG. The MSYS2 installer-signing primary-key fingerprint is 0EBF 782C 5D53 F7E5 FB02 A667 46BD 761F 7A49 B0EC. A successful verification must report Good signature, and the displayed primary fingerprint must match. Do not treat a signature from an unrelated key as confirmation that the installer is genuine.
2. Install MSYS2
- Run the downloaded .exe installer.
- Enter the desired Installation Folder, or keep the recommended default.
- Complete the installation wizard.
- Click Finish.
The default location, C:\msys64, is a good choice. If you select another folder, use a short path on an NTFS volume containing only ordinary ASCII characters. Avoid spaces, accented characters, symbolic links, subst drives, and network drives.
For example, C:\msys64 is suitable. A path such as C:\Users\Jöhn Smith\Downloads\Development Tools\msys64 can create avoidable problems. Some build tools do not handle spaces or non-ASCII characters correctly. Long paths can also run into Windows’ traditional MAX_PATH limit of 260 characters. Enabling Windows long-path support does not guarantee that every compiler, library, or build script supports long paths. See the MSYS2 installer guide.
3. Open the MSYS2 UCRT64 terminal
After installation, MSYS2 normally launches a terminal for the UCRT64 environment. If it does not open automatically, open the Windows Start menu and select MSYS2 UCRT64.
MSYS2 has several environments, and the environment determines which compiler, runtime, libraries, and binary paths are used. If you are unsure which one to choose, MSYS2 recommends UCRT64.
Rank #2
- 【USB C Male to USB 3.0 Female Adapter】Convert the USB C port of the PC, laptop or other devices to a USB A port, and then connect the flash drive or other standard USB A device. It can also provide a maximum data transfer rate of 5Gbps.
- 【USB 3.0 Male to USB C Female Adapter】Convert the USB A port of the laptops, chargers, or other devices to a USB C port, so you can connect USB C peripherals to devices. It can also provide a maximum data transfer rate of 5Gbps.
- 【Micro USB Male to USB C Adapter】Allows you to use USB Type C cable to charge and transfer data for Micro USB mobile devices, which helps to reduce the number of cables you carry with you. Supports up to 2.4A of power and provides a maximum data transfer rate of 480Mbps.
- 【Compact and Easy to Use】The adapters are made of space gray aluminum alloy and black plastic, ultra thin size, ultra compact design, fine appearance details and strict quality inspection standards. And does not require additional drivers and software, plug and play.
- 【What you'll get】2 x micro USB male to USB C adapter, 2 x USB male to USB C adapter, 2 x USB C male to USB adapter. And they can be connected to each other for charging and data transfer.
| Environment | Purpose |
|---|---|
| UCRT64 | Current general-purpose native Windows environment using GCC, UCRT, and libstdc++ |
| MINGW64 | Older MSVCRT-based 64-bit environment; deprecated for new general-purpose use |
| MSYS | Unix-like MSYS tools; not the environment to use for a native MinGW Windows build |
MSYS2 changed its general default from MINGW64 to UCRT64 on October 29, 2022, began deprecating MINGW64 on March 15, 2026, and began phasing out 32-bit environments, including MINGW32, in December 2023. A current Windows 11 guide should start with UCRT64 rather than a generic 32-bit MinGW installer. See MSYS2 environment documentation.
Free tools Windows power users keep installed
One-click scans. No signup required.
4. Install the MinGW-w64 GCC toolchain
In the MSYS2 UCRT64 terminal, run: pacman -S mingw-w64-ucrt-x86_64-gcc.
When pacman displays :: Proceed with installation? [Y/n], press Enter to accept the default yes response. The package manager will download GCC and install required dependencies.
The live package version can change after publication. The current package listing identifies mingw-w64-ucrt-x86_64-gcc as version 16.1.0-6, with a build date of August 1, 2026. Use the package page for the current version rather than relying on an old version shown in an installation example.
5. Confirm that GCC is installed
Remain in the same UCRT64 terminal and run: gcc –version.
You should see GCC version information. The exact version may differ because MSYS2 updates packages independently of the installer. To display the installed MSYS2 package version specifically, run: pacman -Qi mingw-w64-ucrt-x86_64-gcc | grep Version.
If the terminal reports “gcc: command not found,” check the following before reinstalling:
Rank #3
- USB OTG(On The Go): Plug in and use computer peripherals, such as flash drive, keyboard, hub, mouse and more, makes your USB C devices compatible with USB drives and any other USB devices that support OTG. Not compatible with video output.
- USB 3.0 Super Speed Transfer: Full USB 3.0 super speed data transfer up to 5Gbps, 10x faster than USB 2.0; Transfer files, HD movies and songs to your USB C devices in seconds
- Nylon Tangle-free Design: Tangle-free nylon braided design, premium nylon braided cable adds additional durability and tangle free
- Aluminum Body: Made out of sturdy aluminum alloy, innovative engineering ensures durability and a long life span
- What you get: We provide this 2 USB C adapters. If you have any questions,we will resolve your issue within 24 hours; Compatible with all USB C devices, Compatible with iPhone 18 Pro, iPhone 18 Pro Max, iPhone Duo, Samsung Galaxy S26/S25/S24/S23, MacBook Pro/Air, LG G6 G5 V20 and more.
- Confirm that the window title or Start menu shortcut is MSYS2 UCRT64, not MSYS2 MSYS.
- Close and reopen the UCRT64 terminal after installation.
- Run the package query command above to confirm that the GCC package is installed.
6. Compile a test C program
Create a file named hello.c in a convenient directory, with this content:
#include <stdio.h>
int main(void) { printf(“Hello, Windows!\n”); return 0; }
Recommended Free Tools
In the UCRT64 terminal, change to the directory containing the file. If it is in a Windows folder such as C:\Users\YourName\Documents\c-test, the corresponding MSYS2 path is usually /c/Users/YourName/Documents/c-test.
Compile it with gcc hello.c -o hello.exe. This creates a native Windows executable named hello.exe. Run it from the same terminal with ./hello.exe. The expected output is Hello, Windows!.
Why the UCRT64 terminal matters
The UCRT64 terminal configures its internal PATH so that /ucrt64/bin comes before /usr/bin. This ensures that commands such as gcc resolve to the UCRT64 native Windows compiler rather than tools belonging to the MSYS environment.
Do not use the plain MSYS2 MSYS shell for a native MinGW build. MSYS provides Unix-like tools under /usr; it is not the mingw-w64 compiler environment intended for producing Windows applications.
Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Also avoid mixing libraries or object files built for different C runtimes. MSVCRT and UCRT targets have differences in internal structures and data types. A project built for UCRT64 should use UCRT-compatible libraries and dependencies. UCRT is included with Windows 10 and later and generally provides better compatibility with modern Microsoft Visual C++ software.
Rank #4
- 【Note that functional limitations】 : This is a USB-C female to USB-A male adapter designed for charging or data transfer and it will NOT support vidoe signal transmission. (Note: Due to the incompatibility of charging protocols, this adapter doesn't fit your 12 Magsafe Charger or charge MacBook.)
- 【Fast and Quick】 : Offer USB 2.0 data transfer speed up to 480 Mbps and supports 3A power output for charging.
- 【Plug and play】 : With this adapter plugged into an available standard USB port, your legacy devices (charger, power bank, computer) can turn into a USB-C enabled platform.
- 【Safe and Durable】 : Designed and constructed with high quality materials for maximum reliability and durability,and built-in Double sided 56KΩ resistor in this USB-C to USB adapter ensures charging and data transferring safe.
- 【Compatible with】 : iPhone X 11 12 13 14 15 16 17 Pro Max, Apple Watch iWatch Series SE 7 8 Ultra, iPad pro iPad Air iPad mini 6, Samsung Galaxy S25 S25+ S25 Ultra, S24 S24+ S24 Ultra, S23 S23+ S23 Ultra, S22 S22+ S22 Ultra, S21 S21+ S21 Ultra, S20 S20+ S20 Ultra, Note 10 Note 20, Google Pixel 7 7a 6 5 4 4a 3 3A 2 XL and more other Type-C supported devices.
Should you add MinGW to the Windows PATH?
Usually, no. The MSYS2 UCRT64 shortcut already sets the correct compiler path inside the MSYS2 terminal. Adding a random directory to the Windows system PATH can cause Windows, an IDE, or another terminal to invoke a different GCC installation.
The UCRT64 compiler binaries are under the MSYS2 installation directory’s ucrt64\bin folder. For example, with the default installation, the physical folder is C:\msys64\ucrt64\bin.
Use the MSYS2 UCRT64 terminal when following MSYS2-based build instructions. If an IDE needs a compiler path, configure it deliberately for this toolchain rather than adding several MinGW, MSYS, and MINGW64 directories to PATH.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Common mistakes
| Problem | Correction |
|---|---|
| Using pacman -S mingw-w64-x86_64-gcc | Use pacman -S mingw-w64-ucrt-x86_64-gcc for the current UCRT64 setup. |
| Opening MSYS2 MSYS instead of UCRT64 | Launch MSYS2 UCRT64 from the Start menu. |
| Installing into a path with spaces or accents | Use the default C:\msys64 or another short ASCII-only NTFS path. |
| Mixing MSVCRT and UCRT libraries | Keep the compiler, objects, static libraries, and dependencies on the same CRT target. |
| Following a 32-bit MinGW guide | Use the 64-bit UCRT64 environment unless a specific legacy project requires another target. |
| Adding multiple compiler folders to Windows PATH | Use the environment shortcut’s configured path and remove conflicting toolchain entries if necessary. |
Updating GCC later
MSYS2 is a rolling distribution, so installed packages can be updated through its package manager. Run updates from the appropriate MSYS2 terminal and follow any prompts shown by pacman. Do not assume that the version printed in an old tutorial or screenshot is still current.
If a project requires MINGW64/MSVCRT specifically, follow that project’s documented environment and dependency requirements. Otherwise, UCRT64 is the appropriate starting point for a new Windows 11 GCC installation.
FAQ
Is MinGW the same thing as MSYS2?
No. MinGW-w64 is the native Windows compiler and runtime toolchain, while MSYS2 is the distribution and package-management environment used to install it. For a current setup, install MSYS2 and use pacman to install the UCRT64 GCC package.
Which MinGW package should I install on Windows 11?
For a new 64-bit Windows 11 setup, open the MSYS2 UCRT64 terminal and run pacman -S mingw-w64-ucrt-x86_64-gcc. The older mingw-w64-x86_64-gcc package belongs to the MINGW64/MSVCRT environment.
Best Value
- REINFORCED SR CABLE JOINT:AINOPE USB 3.0 extension cable with test of 400,000+ bend, the special SR design makes the cable joints more sturdy. The flexible and wear-resistant armor nylon braided material offers stronger protection. The Included sticky buckles helps to shorten the length and keeps the USB 3.0 extension cable in an organized manner, no tangling worries and effectively prolong the service life.
- UPGRADED CONNECTOR:This USB extension cable with all-metal shell and aluminum alloy connector, provides you fancy texture with good hand-feeling, and ensure the extreme durability. Also constructed with multiple layers of shielding to minimize interference, corrosion-resistant , effectively prolong the cable service life.
- USB3.0 FAST CHARGING & DATA SYNCING:Charging and data transmission two in one, Our USB 3.0 extension cable is 10X faster than USB2.0 cable, also, this USB 3.0 extension cable backwards compatible with USB 2.0 and USB 1.1 standard devices
- UNIVERSAL COMPATIBILITY:You can using this cable to extends your usb connection to your computer, as well as a variety of USB peripherals such as Hubs, Printers, Card Readers, Bluetooth Adapters, USB Flash Drives, Scanners, Hard Drives, Mouse, Keyboard without any hysteresis or loss of data.
- WORRY-FREE SERVICE: If you have any questions about our product, please feel free to contact with our reliable customer service, we will reply you within 24 hours. Package: USB 3.0 Extension Cable Cable*2
Can I use MSYS2 on Windows ARM64?
Yes. MSYS2 provides a Windows ARM64 installer. Download it from the official MSYS2 Installation page. The Intel/AMD installer is for x86-64 Windows systems.
Do I need to add C:\msys64\ucrt64\bin to PATH?
Not when compiling inside the MSYS2 UCRT64 terminal. That shortcut configures the terminal’s internal path. Adding several compiler directories to Windows PATH can cause the wrong GCC or runtime environment to be selected.
Why does gcc work in UCRT64 but not in MSYS2 MSYS?
The terminals represent different environments. UCRT64 adds /ucrt64/bin before /usr/bin, exposing the native UCRT64 compiler. The MSYS environment contains Unix-like tools and is not the normal shell for native MinGW Windows builds.
What is the difference between UCRT64 and MINGW64?
UCRT64 links against Microsoft’s Universal C Runtime and is the current recommended general-purpose environment. MINGW64 uses the older MSVCRT runtime and is deprecated for new general-purpose installations. Use MINGW64 only when a project specifically requires MSVCRT compatibility.
Do these 3 things before closing this tab:
1Repair Windows errors before they cause bigger problems2Scan for outdated or missing drivers - takes under a minute3Clear out junk files and repair common Windows errorsThe Bottom Line
Install MSYS2 from msys2.org, keep the recommended short installation path, open MSYS2 UCRT64, and run pacman -S mingw-w64-ucrt-x86_64-gcc.
Verify the installation with gcc –version, then compile a test program using gcc hello.c -o hello.exe. This gives Windows 11 a current native GCC toolchain without mixing obsolete MINGW64, MSYS, or 32-bit configurations.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

