Hint
Task outputs are hashed by inputs (files + env vars); cache hits skip execution entirely — local and remote caches both supported
Turborepo speeds up monorepo builds through content-addressed caching and parallel execution.
Caching mechanism:
turbo.json, the task's dependencies' output hashes.// turbo.json
{
"pipeline": {
"build": {
"dependsOn": ["^build"], // build deps first
"outputs": ["dist/**"],
"env": ["NODE_ENV"] // include in hash
},
"test": {
"dependsOn": ["build"],
"outputs": []
}
}
}
Remote cache — Turborepo can push/pull cache to Vercel Remote Cache or a self-hosted HTTP cache. First CI run populates it; all subsequent machines (and developer laptops) benefit.