Search code examples
c#nuget

NuGet.org how to specify GPL3 license?


When creating a NuGet package how do I specify the GPL3 license?

I tried to add the following to my csproj file:

<PackageLicenseExpression>GPLv3</PackageLicenseExpression>
<PackageLicenseExpression>GPL3</PackageLicenseExpression>

Nuget.org can't recognize any of those.

But the following does work:

<PackageLicenseExpression>MIT</PackageLicenseExpression>


Solution

  • <PackageLicenseExpression>GPL-3.0-or-later</PackageLicenseExpression>

    You can also find the full list here: https://spdx.org/licenses/