![]() |
VOOZH | about |
dotnet add package Microsoft.Windows.CsWin32 --version 0.3.298
NuGet\Install-Package Microsoft.Windows.CsWin32 -Version 0.3.298
<PackageReference Include="Microsoft.Windows.CsWin32" Version="0.3.298">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageVersion Include="Microsoft.Windows.CsWin32" Version="0.3.298" />Directory.Packages.props
<PackageReference Include="Microsoft.Windows.CsWin32"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>Project file
paket add Microsoft.Windows.CsWin32 --version 0.3.298
#r "nuget: Microsoft.Windows.CsWin32, 0.3.298"
#:package Microsoft.Windows.CsWin32@0.3.298
#addin nuget:?package=Microsoft.Windows.CsWin32&version=0.3.298Install as a Cake Addin
#tool nuget:?package=Microsoft.Windows.CsWin32&version=0.3.298Install as a Cake Tool
Get immediate access to the full Win32 API from C#, just by naming the APIs you require. Generated APIs will be accurate for your CPU architecture and target Windows version. All APIs are generated directly into your project, allowing you to ship without any additional runtime dependencies.
Reach functionality that .NET doesn't expose via the Base Class Library (BCL) to give your library or application that feature that really sets it apart.
Install this package, then create a NativeMethods.txt file with a list of any APIs you need for example:
NativeMethods.txt:
CreateFile
IUIRibbon
S_OK
NTSTATUS
IsPwrHibernateAllowed
ISpellChecker
Any supporting APIs (e.g. enums, structs) are automatically generated when they are required by what you've directly asked for.
Call extern methods through the PInvoke class
using SafeHandle f = PInvoke.CreateFile(
"some.txt",
(uint)GENERIC_ACCESS_RIGHTS.GENERIC_READ,
FILE_SHARE_MODE.FILE_SHARE_READ,
lpSecurityAttributes: null,
FILE_CREATION_DISPOSITION.CREATE_ALWAYS,
FILE_FLAGS_AND_ATTRIBUTES.FILE_ATTRIBUTE_NORMAL,
hTemplateFile: null);
Learn more from our README on GitHub.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 net5.0 was computed. net5.0-windows net5.0-windows was computed. net6.0 net6.0 was computed. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 was computed. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 was computed. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
| .NET Core | netcoreapp1.0 netcoreapp1.0 was computed. netcoreapp1.1 netcoreapp1.1 was computed. netcoreapp2.0 netcoreapp2.0 was computed. netcoreapp2.1 netcoreapp2.1 was computed. netcoreapp2.2 netcoreapp2.2 was computed. netcoreapp3.0 netcoreapp3.0 was computed. netcoreapp3.1 netcoreapp3.1 was computed. |
| .NET Standard | netstandard1.0 netstandard1.0 is compatible. netstandard1.1 netstandard1.1 was computed. netstandard1.2 netstandard1.2 was computed. netstandard1.3 netstandard1.3 was computed. netstandard1.4 netstandard1.4 was computed. netstandard1.5 netstandard1.5 was computed. netstandard1.6 netstandard1.6 was computed. netstandard2.0 netstandard2.0 was computed. netstandard2.1 netstandard2.1 was computed. |
| .NET Framework | net20 net20 is compatible. net35 net35 was computed. net40 net40 was computed. net403 net403 was computed. net45 net45 was computed. net451 net451 was computed. net452 net452 was computed. net46 net46 was computed. net461 net461 was computed. net462 net462 was computed. net463 net463 was computed. net47 net47 was computed. net471 net471 was computed. net472 net472 was computed. net48 net48 was computed. net481 net481 was computed. |
| MonoAndroid | monoandroid monoandroid was computed. |
| MonoMac | monomac monomac was computed. |
| MonoTouch | monotouch monotouch was computed. |
| Tizen | tizen30 tizen30 was computed. tizen40 tizen40 was computed. tizen60 tizen60 was computed. |
| Universal Windows Platform | uap uap was computed. uap10.0 uap10.0 was computed. |
| Windows Phone | wp8 wp8 was computed. wp81 wp81 was computed. wpa81 wpa81 was computed. |
| Windows Store | netcore netcore was computed. netcore45 netcore45 was computed. netcore451 netcore451 was computed. |
| Xamarin.iOS | xamarinios xamarinios was computed. |
| Xamarin.Mac | xamarinmac xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos xamarinwatchos was computed. |
Showing the top 4 NuGet packages that depend on Microsoft.Windows.CsWin32:
| Package | Downloads |
|---|---|
|
Uno.WinUI.Runtime.Skia.Win32
This package provides the platform support for Skia in Uno Platform projects. |
|
|
Morphic.WindowsNative
Morphic Windows Native features library (C#) |
|
|
OverlaySharp
Draws graphics using SkiaSharp(OpenGL) on a transparent window for a target process, with full Native AOT compatibility. |
|
|
SystemHarness.Windows
Windows implementation of SystemHarness — Win32, DXGI, SendInput primitives. |
Showing the top 20 popular GitHub repositories that depend on Microsoft.Windows.CsWin32:
| Repository | Stars |
|---|---|
|
files-community/Files
A modern file manager that helps users organize their files and folders.
|
|
|
DevToys-app/DevToys
A Swiss Army knife for developers.
|
|
|
AvaloniaUI/Avalonia
Develop Desktop, Embedded, Mobile and WebAssembly apps with C# and XAML. The future of .NET UI
|
|
|
Devolutions/UniGetUI
UniGetUI: The Graphical Interface for your package managers. Could be terribly described as a package manager manager to manage your package managers
|
|
|
dotnet/roslyn
The Roslyn .NET compiler provides C# and Visual Basic languages with rich code analysis APIs.
|
|
|
netchx/netch
A simple proxy client
|
|
|
Flow-Launcher/Flow.Launcher
:mag: Quick file search & app launcher for Windows with community-made plugins
|
|
|
winsw/winsw
A wrapper executable that can run any executable as a Windows service, in a permissive license.
|
|
|
d2phap/ImageGlass
🏞 A fast, open-source, modern image viewer for 90+ formats – including WEBP, GIF, SVG, AVIF, JXL, HEIC and more – built for smooth browsing across Windows, macOS, and Linux.
|
|
|
memstechtips/Winhance
Application designed to optimize, customize and enhance your Windows experience.
|
|
|
unoplatform/uno
Open-source platform for building cross-platform native Mobile, Web, Desktop and Embedded apps quickly. Create rich, C#/XAML, single-codebase apps from any IDE. Hot Reload included! 90m+ NuGet Downloads!!
|
|
|
MahApps/MahApps.Metro
A framework that allows developers to cobble together a better UI for their own WPF applications with minimal effort.
|
|
|
lepoco/wpfui
WPF UI provides the Fluent experience in your known and loved WPF framework. Intuitive design, themes, navigation and new immersive controls. All natively and effortlessly.
|
|
|
LibreHardwareMonitor/LibreHardwareMonitor
Libre Hardware Monitor is free software that can monitor the temperature sensors, fan speeds, voltages, load and clock speeds of your computer.
|
|
|
dotnet/wpf
WPF is a .NET Core UI framework for building Windows desktop applications.
|
|
|
stride3d/stride
Stride (formerly Xenko), a free and open-source cross-platform C# game engine.
|
|
|
BartoszCichecki/LenovoLegionToolkit
Lightweight Lenovo Vantage and Hotkeys replacement for Lenovo Legion laptops.
|
|
|
STranslate/STranslate
A ready-to-go translation ocr tool developed with WPF/WPF 开发的一款即用即走的翻译、OCR工具
|
|
| beeradmoore/dlss-swapper | |
|
Sylinko/Everywhere
On-screen aware AI assistant for your desktop. Uses current app context, multiple LLMs, and MCP tools to help you act across apps.
|
| Version | Downloads | Last Updated |
|---|---|---|
| 0.3.298 | 64 | 6/17/2026 |
| 0.3.296 | 2,435 | 6/14/2026 |
| 0.3.287 | 3,270 | 6/11/2026 |
| 0.3.275 | 111,328 | 4/15/2026 |
| 0.3.269 | 166,413 | 1/16/2026 |
| 0.3.264 | 61,135 | 12/13/2025 |
| 0.3.259 | 23,936 | 12/4/2025 |
| 0.3.257 | 54,252 | 11/25/2025 |
| 0.3.253 | 7,411 | 11/23/2025 |
| 0.3.252 | 13,191 | 11/20/2025 |
| 0.3.250 | 4,974 | 11/20/2025 |
| 0.3.248 | 8,630 | 11/15/2025 |
| 0.3.242 | 18,678 | 11/4/2025 |
| 0.3.238 | 8,900 | 10/31/2025 |
| 0.3.236 | 7,074 | 10/30/2025 |
| 0.3.235 | 5,694 | 10/29/2025 |
| 0.3.228 | 10,059 | 10/22/2025 |
| 0.3.217 | 10,518 | 10/16/2025 |
| 0.3.213 | 10,214 | 10/14/2025 |
| 0.3.205 | 65,433 | 9/10/2025 |