What this thread does
npm ERR! code ETARGET npm cannot select an eligible version for the package specification named in the accompanying notarget line. Do first: run npm view <package> versions --json, replacing the placeholder with that package name; compare its available versions with the exact request in the error. Evidence: npm documents version metadata and date filters, while dated reports show both unavailable versions and filter-related failures. Not for: pnpm ERR_PNPM_NO_MATCHING_VERSION; see pnpm-invalid-setting-no-matching-version-optional-peer-errors
As of November 2026, the install branches below target npm 11.21.2, released November 3, 2026. The title retains a legacy log prefix; newer logs can begin npm error code ETARGET.
Diagnostic: No matching version found
The package and requested range after this text are essential. A real version can still be ineligible because of the registry or a date filter.
Choose the branch
1. npm 11.21.2: no published version satisfies the request. Use npm view to inspect versions and dist-tags. For a direct dependency, replace the mistaken version or range in package.json with an available, compatible release, then run npm install. For a transitive request, select a compatible parent release whose dependency metadata fixes it; inspect that release with npm view <parent>@<version> dependencies --json. Replace every placeholder. Check: the selected version satisfies the corrected range and installation proceeds past that notarget error. Publishing histories need not contain every possible version number.
2. npm 11.21.2: the version exists elsewhere but not in this registry. Run npm config get registry; for a scoped package also run npm config get @scope:registry, substituting its scope. For an unscoped package, compare npm view <package> versions --json --registry=<intended-registry-url> against the default lookup. For a scoped package, correct its scope-specific registry mapping and repeat the normal lookup. Registry configuration and per-scope npmrc entries determine the destination. Correct the relevant project configuration or let its mirror synchronize. Check: the normal lookup now returns the intended release. Keep private packages on their intended registry.
3. npm 11.21.2: the error includes a date cutoff. Read npm config get before and npm config get min-release-age, then inspect npm view <package> time --json. The date-filter reference excludes otherwise published releases. Choose an older compatible eligible version or wait until the intended version clears the configured window, then rerun the install. Check: the release's publication time falls before the effective cutoff and npm selects it. An explicit before can also constrain selection; waiting does not move an absolute date.
Evidence and limits
Daniela Romero's June 2, 2017 report names ionic-native@^3.5.0. It establishes longstanding demand, not a recommendation to install that old package.
There is a separate execution-path caveat: ffrosch's July 14, 2026 issue reports npx ignoring min-release-age-exclude on npm 12.0.1; slorber reports the symptom on 11.19. Do not infer a fix in 11.21.2 from those reports. The changelog dates that exclusion setting to 11.17.0. An install-time exclusion is not a promise about every execution path.
An ERESOLVE peer conflict has a different cause; see npm-install-eresolve-peer-dependency-conflict-before-force. Changing peer flags does not publish a missing version.
Started from a post by @npm, packaged by the editor. Original post