Skip to content

CI is challenging and it's not your fault. It's a fundamental issue with how the current, traditional CI execution model works. Nx Cloud adopts a new task-based CI model that overcomes slowness and unreliability of the current VM-based CI model.

Nx Cloud improves many aspects of the CI/CD process:

  • Speed - 30% - 70% faster CI (based on reports from our clients)
  • Cost - 40% - 75% reduction in CI costs (observed on the Nx OSS monorepo)
  • Reliability - by automatically identifying flaky tasks (e2e tests in particular) and re-running them

Run the following command in your Nx workspace (make sure you have it pushed to a remote repository first):

Terminal window
npx nx connect

This connects your workspace to Nx Cloud and enables remote caching and CI features. For more details, follow our in-depth guide for setting up CI with Nx.

In traditional CI models, work is statically assigned to CI machines. This creates inefficiencies that many teams experience at scale.

Nx Cloud uses a task-based approach to dynamically assign tasks to agent machines. CI becomes scalable, maintainable, and more reliable because Nx Cloud coordinates work among agent machines automatically and acts on individual tasks directly.

For example:

  • An agent machine fails in a setup step — Nx Cloud automatically reassigns the work to other agent machines.
  • More work needs to run in CI — add more agent machines, Nx Cloud automatically assigns available work.
  • Known flaky tasks waste CI time on needed reruns — Nx Cloud automatically detects flaky tasks and reruns them in the current CI execution.

Learn how our customers use Nx Cloud to scale their workspaces and be more efficient.

AI-Powered Self-Healing CI

Learn how Nx Cloud Self-Healing CI uses AI to automatically detect, analyze, and fix CI failures, eliminating the need to babysit PRs and keeping you focused on building features.

Remote Caching (Nx Replay)

Learn how to use Nx Replay to share computation caches across your team and CI, speeding up builds and saving CI costs.

Distribute Task Execution (Nx Agents)

Learn how to use Nx Agents to distribute task execution across multiple machines, optimizing CI pipeline speed and efficiency through intelligent task allocation.

Run Only Tasks Affected by a PR

Learn how to use Nx affected command to determine and run tasks only on projects affected by your changes, improving CI speed and efficiency.

Dynamically Allocate Agents

Configure Nx Agents to dynamically scale based on PR size for cost-effective CI

Resource usage

Upload and view per-agent CPU and memory metrics for distributed task execution to find bottlenecks, debug out-of-memory errors, and right-size your agents.

Automatically Split Slow Tasks

Automatically split large test tasks into individual file-level tasks for parallel execution

Task sandboxing

Confine each task to its declared inputs and outputs to catch undeclared dependencies and keep caching correct.

Identify and Re-run Flaky Tasks

Automatically detect and re-run flaky tasks in CI with Nx Cloud

GitHub Integration

Connect Nx Cloud with GitHub for seamless onboarding, PR insights, and access control

Dedicated compute cluster

Reserve an isolated Nx Cloud compute environment for your organization and unlock Docker-in-Docker, sandboxing, and read-through caches.

Docker layer caching

Cache Docker build layers across CI runs on Nx Agents to speed up image builds.

Docker read-through cache

Serve repeated Docker image pulls from a cache close to your Nx Agents instead of the upstream registry.

npm read-through cache

Serve repeated npm installs from a cache close to your Nx Agents instead of the public npm registry.