Skip to content
Latchkey

NuGet "error NU1101: Unable to find package" in CI

NuGet queried every configured feed and none of them publishes a package with that id. NU1101 is about the id itself: a typo, a private package whose feed is not configured, or a feed that returned nothing.

What this error means

dotnet restore stops with "error NU1101: Unable to find package X. No packages exist with this id in source(s): nuget.org". The build never reaches compilation.

dotnet
error NU1101: Unable to find package Contoso.Internal.Utils. No packages exist with this id in source(s): nuget.org

Common causes

A misspelled or wrong package id

The id in the PackageReference does not match any published package, so every feed returns nothing for it.

A private feed is not configured in CI

The package lives on an internal feed that the runner has no nuget.config source for, so only nuget.org is searched and the id is absent.

How to fix it

Confirm the id and the source list

  1. Check the exact Include value on the PackageReference against the feed.
  2. Confirm the feed that hosts the package is listed in nuget.config.
  3. Re-run dotnet restore and verify the source(s) line now includes that feed.
Project.csproj
<PackageReference Include="Contoso.Internal.Utils" Version="1.4.0" />

Add the private feed as a source

Register the internal feed in a committed nuget.config so restore searches it.

nuget.config
<configuration>
  <packageSources>
    <add key="contoso" value="https://pkgs.contoso.com/v3/index.json" />
  </packageSources>
</configuration>

How to prevent it

  • Commit a nuget.config that lists every feed your packages need.
  • Verify package ids against the feed, not the namespace you import.
  • Restore locally with the same nuget.config CI uses.

Related guides

Tired of flaky CI? Latchkey auto-heals failed jobs and retries them for you. Start free →