Skip to content
Projects

microsoft/CsWin32 has 2,527 GitHub stars and 132 forks. GitHot measured +1 stars in 24 hours. Last checked 2026-11-07 20:53 UTC. Last push 2026-11-02.

How these counts are measured

A source generator to add a user-defined set of Win32 P/Invoke methods and supporting types to a C# project.

Measured star growth

in 24h
+1
in 7 days
Collecting history
in 15 days
Collecting history
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

README.md

Original

C#/Win32 Interop Projection

NuGet badge NuGet badge

C#/Win32 provides P/Invoke and COM Interop projection support for C#. It generates strongly-typed, source-generated bindings from CsWn32-compatible .winmd metadata files. CsWin32 supports the metadata of Microsoft.Windows.SDK.Win32Metadata as the 1st-party metadata.

  • Generates interop code quickly at compilation time.
  • Generates friendly overloads/extensions (including SafeHandle-types support).
  • Generates xml documentation based on and links back to learn.microsoft.com
  • Ships no bulky assemblies alongside your application.

Getting started

Demo

Animation demonstrating p/invoke code generation

Explore related projects