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
What you get with Nx Cloud on top of Nx Core
Section titled “What you get with Nx Cloud on top of Nx Core”| Nx Core | Nx Cloud | |
|---|---|---|
| Caching | Local cache, per machine | Adds a remote cache shared across your team and CI |
| Task scheduling | Task graph on one machine, nx affected to skip untouched projects | Adds distribution across agent machines |
| End-to-end tests | Run as one task per project | Split per file and distributed |
| Flaky tasks | You rerun the pipeline | Detected and rerun within the same run |
| Failing CI | You read the logs and fix it | Self-healing CI proposes a fix on the PR |
| Visibility | Terminal output for the run in front of you | Run history, task analytics, and CI observability |
Connect your workspace to Nx Cloud
Section titled “Connect your workspace to Nx Cloud”Run the following command in your Nx workspace (make sure you have it pushed to a remote repository first):
npx nx connectThis 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.
How Nx Cloud improves CI
Section titled “How Nx Cloud improves CI”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.
Nx Cloud features
Section titled “Nx Cloud features”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
Share cached task results across developer machines and CI with Nx Cloud remote caching.
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
Understand how your tasks use CPU and memory during CI runs.
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.
Flaky tasks
Nx Cloud detects flaky tasks - tests, e2e runs, or builds - by tracking results for the same task hash across CI runs, then retries them on a different agent.
GitHub Actions integration
Speed up GitHub Actions for your monorepo with Nx: run only affected projects, share a remote cache, and add PR insights and self-healing CI with Nx Cloud.
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.
Frequently asked questions
Section titled “Frequently asked questions”Is Nx Cloud free?
Section titled “Is Nx Cloud free?”Yes. Nx Cloud starts on the free Hobby plan, which includes 50,000 credits per month, 5 contributors, and 10 concurrent CI connections, with no credit card.
Nx itself is free and open source too. Task running, the project graph, local caching, nx affected, generators, and migrations all work without an Nx Cloud account.
What happens when I use up my credits?
Section titled “What happens when I use up my credits?”On the Hobby plan, Nx Cloud features turn off once the monthly credits are gone and turn back on at the next reset.
The Team plan has no such cap, and usage beyond the $29 of included credit is billed at $5.50 per 10,000 credits. See credit pricing for what each operation costs.
Do unused credits carry over?
Section titled “Do unused credits carry over?”No. Your allowance resets at the start of each billing cycle.
Is there a plan for open source projects?
Section titled “Is there a plan for open source projects?”Yes. Nx Cloud is free for qualifying open source organizations. Talk to our engineering team to get set up.
Can I get a shared cache without Nx Cloud?
Section titled “Can I get a shared cache without Nx Cloud?”Yes. Build your own server against the remote cache OpenAPI specification, in any language. You maintain the storage, authentication, and uptime.
When should I consider Enterprise or self-hosted options?
Section titled “When should I consider Enterprise or self-hosted options?”The Enterprise plan adds SSO and SAML, dedicated support with SLAs, conformance rules, code owners, and cross-repo visibility.
On a single-tenant instance or an on-prem install, you choose the region and the infrastructure your cache and run data live on. For what a standard Nx Cloud workspace sends and stores, see the privacy policy.