Visual Studio 2026 and Windows 10 compatibility

All Windows SDK versions have supported targeting multiple Windows versions.

API surface is controlled by macro (WINVER and/or _WIN32_WINNT), see Update WINVER and _WIN32_WINNT and Using the Windows Headers: Setting WINVER or _WIN32_WINNT

When you use the Windows SDK, you can specify which versions of Windows your code can run on. The preprocessor macros WINVER and _WIN32_WINNT specify the minimum operating system version your code supports. Visual Studio and the Microsoft C++ compiler support targeting Windows 7 SP1 and later. Older build tools include support for Windows XP SP2, Windows Server 2003 SP1, Vista, and Windows Server 2008. Windows 95, Windows 98, Windows ME, Windows NT, and Windows 2000 are unsupported.

Sometimes you also need the /SUBSYSTEM:WINDOWS,x.y argument to LINK.exe or EDITBIN.exe, for example /SUBSYSTEM:WINDOWS,5.1 was needed to run on Windows XP (as well as a different C++ runtime import library). But you only need to do this when targeting OS versions that are no longer officially supported, because the default value here is the oldest supported version.

Read more here: Source link