Skip to content
Latchkey

dotnet nuget push "409 Conflict" version already exists in CI

A 409 on push means the exact package version already exists on the feed. Most feeds are immutable, so republishing the same version is rejected rather than overwritten.

What this error means

push fails with "Response status code does not indicate success: 409 (Conflict)" or "already exists" for the package and version being pushed.

dotnet
error: Response status code does not indicate success: 409 (Conflict).
      Package 'Contoso.Utils 1.4.0' already exists on the feed.

Common causes

The version was already published

A prior CI run, or a manual push, already uploaded this exact version. The feed will not overwrite an existing immutable version.

The version was not bumped for a new build

CI pushes on every merge but the package version is static, so the second push collides with the first.

How to fix it

Bump the version before pushing

  1. Increment the package version for each publish (or derive it from the build).
  2. Pack with the new version.
  3. Push again; a unique version avoids the 409.
Terminal
dotnet pack -p:PackageVersion=1.4.1
dotnet nuget push bin/Release/Contoso.Utils.1.4.1.nupkg --source private --api-key ${{ secrets.NUGET_KEY }}

Skip duplicates on idempotent republish

If re-pushing the same version is expected, pass --skip-duplicate so an existing version is a no-op instead of a 409 failure.

Terminal
dotnet nuget push *.nupkg --source private --api-key ${{ secrets.NUGET_KEY }} --skip-duplicate

How to prevent it

  • Derive a unique package version from the build (tag, run number, or commit).
  • Use --skip-duplicate when republishing is idempotent by design.
  • Never rely on overwriting an existing immutable version.

Frequently asked questions

What causes ""409 Conflict""?
A prior CI run, or a manual push, already uploaded this exact version. The feed will not overwrite an existing immutable version.
How do I fix "409 Conflict"?
Bump the version before pushing

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card