# Bring Your Kotlin Library to NuGet

Integrate Kotlin into C# with the kotlin-native-nuget plugin.

- **Source:** [ProAndroidDev - Medium](https://brifing.si/source/d9553fa9-7b72-4b9b-bc73-c6bf9a40dd5f)
- **Published:** 2026-07-19
- **Topic:** [Software & Engineering](https://brifing.si/c/engineering)
- **Original article:** <https://proandroiddev.com/bring-your-kmp-library-to-nuget-02e1131a4707?source=rss----c72404660798---4>
- **On Brifing:** https://brifing.si/s/c8ed1d81-0ab6-48e5-9ce1-b724278b4728

## What is kotlin-native-nuget?

Kotlin-native-nuget is a Gradle plugin that packages Kotlin libraries as NuGet packages and generates C# bindings. This plugin allows you to make your Kotlin code usable for C# developers.

## How Does It Work?

The plugin compiles Kotlin/Native code and automatically generates bindings for C#. These bindings present Kotlin's features in a way that is natural to C#.

## Integration Process

After adding the plugin to your project, you can specify your Kotlin/Native targets and run the publish task. This process results in a .nupkg file.

## Ease for C# Developers

C# developers can add the generated NuGet package to their projects and use Kotlin code as if it were C#. This provides seamless integration between Kotlin and .NET ecosystems.

## Features and Benefits

The plugin transfers Kotlin's features such as classes, enums, data classes, coroutines, Flow, generics, and interfaces to C#. This offers significant convenience for C# developers.

## Technical Details

The plugin converts the Kotlin API into a C# Intermediate Representation (CIR) model and renders this model into an Interop.cs file. This file is included pre-generated within the NuGet package.

## Why It Matters

Kotlin-native-nuget bridges the Kotlin and .NET ecosystems, reducing developers' workload and facilitating code sharing. This is a crucial step for multi-platform development.

## Sources covering this story

- https://proandroiddev.com/bring-your-kmp-library-to-nuget-02e1131a4707?source=rss----c72404660798---4 — 

---

_Summary written by Brifing from the original reporting. Copyright in the original article belongs to its publisher; read the full piece at the link above._
