---
title: "Upgrade"
description: "Upgrade your Shelve CLI to the latest version."
canonical_url: "https://shelve.cloud/docs/cli/upgrade"
---
# Upgrade

> Upgrade your Shelve CLI to the latest version.

Checks npm for a newer `@shelve/cli` version and updates the dependency in your project.

```bash [terminal]
shelve upgrade
shelve --json upgrade
```

## Behaviour

1. Compares the installed version with the npm `latest` tag.
2. If already up to date, exits successfully.
3. Otherwise runs `nypm addDependency('@shelve/cli@latest')`.

Global `--yes` / non-interactive mode skips any interactive steps during the upgrade flow.

## JSON output

```json
{
  "ok": true,
  "command": "upgrade",
  "data": {
    "previous": "5.0.3",
    "current": "latest",
    "updated": true
  }
}
```

When already current: `"updated": false` and `"current"` matches `"previous"`.


## Sitemap

See the full [sitemap](https://shelve.cloud/sitemap.md) for all pages.
