The **Windows API**, informally **WinAPI**, is Microsoft's core set of application programming interfaces (**APIs**) available in the **Microsoft Windows** operating systems. The name **Windows API** collectively refers to several different platform implementations that are often referred to by their own names (for example, **Win32 API**); see the versions section. Almost all Windows programs interact with the **Windows API**. On the [[Windows NT]] line of operating systems, a small number (such as programs started early in the Windows startup process) use the [[Native API]]. Developer support is available in the form of a [[software development kit]], [[Microsoft Windows SDK]], providing documentation and tools needed to build software based on the **Windows API** and associated Windows interfaces. The **Windows API** (**Win32**) is focused mainly on the programming language [[:C]] in that its exposed functions and data structures are described in that language in recent versions of its documentation. However, the **API** may be used by any programming language compiler or assembler able to handle the (well-defined) low-level data structures along with the prescribed calling conventions for calls and callbacks. Similarly, the internal implementation of the **API's** function has been developed in several languages, historically. Despite the fact that [[:C]] is not an object-oriented programming language, the **Windows API** and **Windows** have both historically been described as object-oriented. There have also been many wrapper classes and extensions (from Microsoft and others) for object-oriented languages that make this object-oriented structure more explicit (Microsoft Foundation Class Library ([[MFC]]), Visual Component Library ([[VCL]]), [[GDI+]], etc.). For instance, Windows 8 provides the **Windows API** and the [[WinRT API]], which is implemented in C++ and is object-oriented by design. ====== Versions ====== Almost every new version of **Microsoft Windows** has introduced its own additions and changes to the **Windows API**. The name of the **API**, however, remained consistent between different Windows versions, and name changes were kept limited to major architectural and platform changes for Windows. Microsoft eventually changed the name of the then current **Win32 API** family into **Windows API** and made it into a catch-all term for both past and future **API** versions. * **Win16** is the **API** for the first, **16-bit** versions of Microsoft Windows. These were initially referred to as simply the **Windows API**, but were later renamed to **Win16** in an effort to distinguish them from the newer, 32-bit version of the **Windows API**. The functions of **Win16 API** reside in mainly the core files of the OS: **kernel.exe** (or **krnl286.exe** or **krnl386.exe**), **user.exe** and **gdi.exe**. Despite the file extension of exe, these actually are dynamic-link libraries. * **Win32** is the **32-bit** application programming interface (**API**) for **32-bit** versions of Windows ([[Windows NT|NT]], [[Windows 95|95]], and later versions). The **API** consists of functions implemented, as with **Win16**, in system DLLs. The core DLLs of **Win32** are **kernel32.dll**, **user32.dll**, and **gdi32.dll**. **Win32** was introduced with [[Windows NT]]. The version of **Win32** shipped with [[Windows 95]] was initially referred to as **Win32c**, with c meaning compatibility. This term was later abandoned by Microsoft in favor of **Win32**. * **Win32s** is an extension for the [[Windows 3.1]]x family of Microsoft Windows that implemented a subset of the **Win32 API** for these systems. The "s" stands for "subset". * **Win64** is the variant of the **API** implemented on **64-bit** platforms of the Windows architecture (as of 2021, **x86-64** and **AArch64**). Both **32-bit** and **64-bit** versions of an application can be still compiled from one codebase, although some older **APIs** have been **deprecated**, and some of the APIs that were already deprecated in **Win32** were removed. All memory pointers are **64-bit** by default (the **LLP64 model**), so the source code must be checked for compatibility with **64-bit pointer** arithmetic and rewritten as necessary. * **WinCE** is the implementation of the **Windows API** for the [[Windows CE]] operating system.