{"record":{"id":"efd6718fa5c14de4","repo":"angular/angular-cli","slug":"the-installed-angular-cli-version-is-outdated-ins","errorCode":null,"errorMessage":"The installed Angular CLI version is outdated.\nInstalling a temporary Angular CLI versioned ${cliVersionToInstall} to perform the update.","messagePattern":"The installed Angular CLI version is outdated\\.\nInstalling a temporary Angular CLI versioned (.+?) to perform the update\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"packages/angular/cli/src/commands/update/cli.ts","lineNumber":179,"sourceCode":"      })\n      .strict();\n  }\n\n  async run(options: Options<UpdateCommandArgs>): Promise<number | void> {\n    const { logger, packageManager } = this.context;\n\n    // Check if the current installed CLI version is older than the latest compatible version.\n    // Skip when running `ng update` without a package name as this will not trigger an actual update.\n    if (!disableVersionCheck && options.packages?.length) {\n      const cliVersionToInstall = await checkCLIVersion(\n        options.packages,\n        logger,\n        packageManager,\n        options.next,\n      );\n\n      if (cliVersionToInstall) {\n        logger.warn(\n          'The installed Angular CLI version is outdated.\\n' +\n            `Installing a temporary Angular CLI versioned ${cliVersionToInstall} to perform the update.`,\n        );\n\n        return runTempBinary(\n          `@angular/cli@${cliVersionToInstall}`,\n          packageManager,\n          process.argv.slice(2),\n        );\n      }\n    }\n\n    const packages: npa.Result[] = [];\n    for (const request of options.packages ?? []) {\n      try {\n        const packageIdentifier = npa(request);\n\n        // only registry identifiers are supported","sourceCodeStart":161,"sourceCodeEnd":197,"githubUrl":"https://github.com/angular/angular-cli/blob/bb72145f9ab45aee29f523236b3a25cd0813a841/packages/angular/cli/src/commands/update/cli.ts#L161-L197","documentation":"During `ng update`, cliVersionToInstall determines that the currently installed Angular CLI is too old to perform the update migrations. The CLI warns and instead installs a temporary newer @angular/cli (at the computed version) and re-executes the update through its binary via runTempBinary.","triggerScenarios":"Running `ng update @angular/core@<newer-major>` (or with --next) when the locally installed @angular/cli version is lower than the version required to run the target's migrations; checkCLIVersion/cliVersionToInstall returns a version to install.","commonSituations":"Skipping multiple major versions (e.g., updating from v15 to v19); projects where the CLI was not updated alongside the framework; using --next to jump to a pre-release.","solutions":["No action needed: the CLI transparently installs a temporary CLI and continues the update.","To avoid the temporary install, first update the CLI itself: `ng update @angular/cli` then update the framework.","Ensure your package manager (npm/yarn/pnpm/bun) can download @angular/cli@<version> from the registry (network/proxy access).","Update in single-major steps (`ng update @angular/core@16 @angular/cli@16`, etc.) to keep the local CLI adequate at each step."],"exampleFix":"// before\nng update @angular/core@19   # installed CLI is v15\n// after\ngn update stepwise:\nng update @angular/cli@16 @angular/core@16\nng update @angular/cli@17 @angular/core@17\n# ... until target version","handlingStrategy":"validation","validationCode":"import { execSync } from 'node:child_process';\nconst cliVer = JSON.parse(execSync('npm ls @angular/cli --json').toString()).dependencies['@angular/cli'].version;\nconst major = parseInt(cliVer.split('.')[0], 10);\nconst target = parseInt(process.env.TARGET_MAJOR!, 10);\nif (major < target) console.warn(`Installed CLI v${major} is behind target v${target}; a temporary CLI will be installed`);","typeGuard":null,"tryCatchPattern":"try {\n  await ngUpdate(['@angular/core@19']);\n} catch (e) {\n  if (String(e.message).includes('temporary Angular CLI')) {\n    // ensure registry access for @angular/cli@<ver> then retry\n  }\n}","preventionTips":["Update @angular/cli and @angular/core together at each major.","Upgrade one major at a time instead of skipping several.","Ensure package manager can reach the npm registry for temporary installs.","Keep CLI version pinned in lockfile so it stays in sync with the framework."],"tags":["update","versioning","angular-cli","migration"],"backgroundTag":"outdated-cli-temporary-install","analyzedSha":"bb72145f9ab45aee29f523236b3a25cd0813a841","analyzedAt":"2026-08-30T02:47:34.745Z","schemaVersion":2},"datasetVersion":"2026-08-30T03:17:51.788Z"}