---
schema_version: "1"
id: 41e7503e23a818b309564579d9b3dd53adda30fa6c007f87128ca85e28a4dcdb
title: Second-Generation Managed Packaging Keywords
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/platform-pkg-exchange/managed_packaging/guides/second-generation/sfdx-dev-dev2gp-config-keywords.md
canonical_url: https://developer.salesforce.com/docs/platform/pkg2-dev/guide/sfdx-dev-dev2gp-config-keywords.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 3bf57a38e3dbf9987b86724551a68c8b69ce179f10a273c7b6271e80c3c3fd6d
products:
  - Second-Generation Managed Packaging Developer Guide
  - merged-docs
---

# Second-Generation Managed Packaging Keywords

A keyword is a variable that you can use to specify a package version number.

You can use keywords to automatically increment the value of the package build numbers, ancestor version numbers, set the package dependency to the latest version, or the latest released and promoted version.

| Use the Keyword                                                                                                                                                                                                                                                                                                                                                                                                                        | Example                           |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------- |
| LATEST to specify the latest version of the package dependency when you create a package version.                                                                                                                                                                                                                                                                                                                                      | See the example after this table. |
| NEXT to increment the build number to the next available for the package version. If you don’t use NEXT, and you also forget to update the version number in your `sfdx-project.json` file, the new package version uses the same number as the previous package version. Although we don’t enforce uniqueness on package version numbers, every package version is assigned a unique subscriber package version ID (starts with 04t). | See the example after this table. |
| RELEASED to specify the latest promoted and released version of the package dependency when you create a package version.                                                                                                                                                                                                                                                                                                              | See the example after this table. |
| HIGHEST to automatically set the package ancestor to the highest promoted and released package version number. Use only with ancestor version or ancestor ID.                                                                                                                                                                                                                                                                          | See the example after this table. |
| NONE in the ancestor version or ancestor ID field. Ancestry defines package upgrade paths. If the package ancestor is set to NONE, an existing customer can’t upgrade to that package version.                                                                                                                                                                                                                                         | See the example after this table. |

Example using LATEST:

```nolang
"dependencies": [
   {
      "package": "MyPackageName",
      "versionNumber": "0.1.0.LATEST"
   }
]
```

Example using NEXT:

```nolang
"versionNumber": "1.2.0.NEXT"
```

Example using RELEASED:

```nolang
"dependencies": [
   {
    "package": "pkgB",
    "versionNumber": "2.1.0.RELEASED"
    }
]

```

Example using HIGHEST:

```nolang
"packageDirectories": [
{
"path": "util",
"package": "Expense Manager - Util",
"versionNumber": "4.7.0.NEXT",
"ancestorVersion": "HIGHEST"
},

```

Example using NONE:

```nolang
"packageDirectories": [
{
"path": "util",
"package": "Expense Manager - Util",
"versionNumber": "4.7.0.NEXT",
"ancestorVersion": "NONE"
},

```
