Important: This documentation covers Yarn 2. For the 1.x doc, check
yarn addyarn binyarn cache cleanyarn config getyarn config setyarn configyarn constraints queryyarn constraints sourceyarn constraintsyarn dlxyarn inityarn installyarn linkyarn nodeyarn npm infoyarn npm loginyarn npm publishyarn npm whoamiyarn packyarn patch-commityarn patchyarn plugin importyarn plugin listyarn plugin runtimeyarn rebuildyarn removeyarn runyarn set resolutionyarn set version from sourcesyarn set versionyarn stageyarn unplugyarn upyarn upgrade-interactiveyarn version applyyarn version checkyarn versionyarn whyyarn workspaceyarn workspaces foreachyarn workspaces list

yarn up

Upgrade dependencies across the project.


$> yarn up [-i,--interactive] [-v,--verbose] [-E,--exact] [-T,--tilde] [-C,--caret] ...


Upgrade all instances of lodash to the latest release :

yarn up lodash

Upgrade all instances of lodash to the latest release, but ask confirmation for each :

yarn up lodash -i

Upgrade all instances of lodash to 1.2.3 :

yarn up lodash@1.2.3


This command upgrades a list of packages to their latest available version across the whole project (regardless of whether they're part of dependencies or devDependencies - peerDependencies won't be affected). This is a project-wide command: all workspaces will be upgraded in the process.

If -i,--interactive is set (or if the preferInteractive settings is toggled on) the command will offer various choices, depending on the detected upgrade paths. Some upgrades require this flag in order to resolve ambiguities.

The, -C,--caret, -E,--exact and -T,--tilde options have the same meaning as in the add command (they change the modifier used when the range is missing or a tag, and are ignored when the range is explicitly set).