Skip to main content
Check for outdated dependencies.
bun outdated

Behavior

bun outdated compares installed package versions against the latest available versions in the registry. It shows which packages have updates available.

Output

The command displays a table with:
  • Package - Package name and type (dev, peer, optional)
  • Current - Currently installed version
  • Update - Latest version matching the semver range
  • Latest - Absolute latest version available
$ bun outdated
bun outdated v1.0.0

┌──────────────────────────────────────────────────────────────┐
 Package Current Update Latest Type
├──────────────────────────────────────────────────────────────┤
 react 18.2.0 18.2.1 19.0.0
 typescript 5.0.0 5.0.4 5.3.3 dev
 @types/node 20.0.0 20.10.5 20.10.5 dev
└──────────────────────────────────────────────────────────────┘

Filtering

Check specific packages

bun outdated react typescript

Pattern matching

# Check all @types/* packages
bun outdated "@types/*"

# Check all packages starting with "babel-"
bun outdated "babel-*"

Check all packages

bun outdated "*"

Workspaces

In a workspace project, check outdated dependencies across all workspaces:
bun outdated --recursive
Check specific workspace:
bun outdated --filter "my-package"
Check multiple workspaces:
bun outdated --filter "@myorg/*"
Output includes workspace information:
┌─────────────────────────────────────────────────────────────────────────┐
│ Package    │ Current │ Update  │ Latest  │ Workspace        │
├─────────────────────────────────────────────────────────────────────────┤
│ react      │ 18.2.0  │ 18.2.1  │ 19.0.0  │ @myorg/frontend  │
│ react      │ 18.2.0  │ 18.2.1  │ 19.0.0  │ @myorg/backend   │
└─────────────────────────────────────────────────────────────────────────┘

Flags

--recursive (-r)

Check outdated dependencies in all workspace packages.
bun outdated --recursive

--filter <pattern>

Check specific workspace(s).
bun outdated --filter "packages/app"
bun outdated --filter "@myorg/*"

--cwd <path>

Run command in specified directory.
bun outdated --cwd ./my-project

--verbose

Show detailed information including all available versions.
bun outdated --verbose

--silent

Suppress output if no packages are outdated (useful in scripts).
bun outdated --silent

Exit codes

  • 0 - No outdated packages or command succeeded
  • 1 - Error occurred
The command doesn’t exit with a non-zero code when outdated packages are found.

Understanding version columns

Current

The version currently installed in node_modules.

Update

The latest version that satisfies the semver range in package.json. For example, if package.json has:
{"react": "^18.2.0"}
And versions available are:
  • 18.2.0 (current)
  • 18.2.1 (patch)
  • 18.3.0 (minor)
  • 19.0.0 (major)
The “Update” column shows 18.3.0 (latest that satisfies ^18.2.0).

Latest

The absolute latest version available in the registry, ignoring semver ranges.

Color coding

Versions are color-coded to show update type:
  • Green - Patch update (1.0.0 → 1.0.1)
  • Yellow - Minor update (1.0.0 → 1.1.0)
  • Red - Major update (1.0.0 → 2.0.0)

Examples

Check all dependencies

$ bun outdated
bun outdated v1.0.0

┌────────────────────────────────────────────────────────┐
 Package Current Update Latest
├────────────────────────────────────────────────────────┤
 react 18.2.0 18.2.1 19.0.0
 typescript 5.0.0 5.0.4 5.3.3
└────────────────────────────────────────────────────────┘

Check specific packages

$ bun outdated react typescript
bun outdated v1.0.0

┌────────────────────────────────────────────────────────┐
 Package Current Update Latest
├────────────────────────────────────────────────────────┤
 react 18.2.0 18.2.1 19.0.0
 typescript 5.0.0 5.0.4 5.3.3
└────────────────────────────────────────────────────────┘

Check with pattern

$ bun outdated "@types/*"
bun outdated v1.0.0

┌──────────────────────────────────────────────────────────┐
 Package Current Update Latest
├──────────────────────────────────────────────────────────┤
 @types/node 20.0.0 20.10.5 20.10.5
 @types/react 18.0.0 18.2.45 18.2.45
└──────────────────────────────────────────────────────────┘

No outdated packages

$ bun outdated
bun outdated v1.0.0

# No output - all packages are up to date

Updating packages

After checking for outdated packages, update them:
# Update to latest compatible versions (respects semver ranges)
bun update

# Update to absolute latest versions (ignores semver ranges)
bun update --latest

# Update specific packages
bun update react typescript

# Interactive update
bun update --interactive
See bun update for details.

CI/CD usage

Check for outdated dependencies in CI:
# Exit successfully even if packages are outdated
bun outdated

# To fail CI if packages are outdated, manually check output
if bun outdated | grep -q "│"; then
  echo "Outdated packages found"
  exit 1
fi

Performance

bun outdated is fast because:
  • It reads from Bun’s package manifest cache
  • It queries registries in parallel
  • It reuses lockfile information when possible
Typical check time for 100+ packages: < 2 seconds

Build docs developers (and LLMs) love