Helix Core is now P4. Product user interfaces will be updated soon. Learn more >>

P4 CLI Documentation | 2026.1

# p4 license

Update or display the license file.

## Syntax

    p4 [g-opts] license -o
    p4 [g-opts] license -i
    p4 [g-opts] license -u
    p4 [g-opts] license -L

Syntax and naming conventions

## Description

The `p4 license` command allows P4 Server superusers to update or display the license file.

You can also use `p4 license` to add licensed users to a P4 Server without having to shut down the service and manually copy the license file into the root directory. Rename the license file you received to the following name:
`license`

In many situations, more steps are necessary than running the `p4 license` command. To learn more, see the following topics in the P4 Server Administration Documentation:

- Install the license file

- Server Licensing

### Avoid surprise expiration

License expiration occurs at the START of the expiration date according to Coordinated Universal Time (UTC). For example, if `p4 license -o` shows the UNIX time for expiration as 1546300801, that means Tuesday, January 1, 2019 12:00:01 AM for UTC (GMT). If your server is in California, the license expires the day before on Monday, December 31, 2018 4:00:01 PM because California local time is 8 hours behind UTC. To convert UNIX time to a more readable format, use a converter, such as https://www.epochconverter.com/.

Alternatively, to get `licenseTimeRemaining` in seconds, use `p4 license -u` as in this example:

    p4 -u su-bruno -p p4prod.mycompany.com:1666 license -u

    The output might be similar to:

Copy

    ... isLicensed yes
    ... userCount 651
    ... userLimit 1000
    ... clientCount -
    ... clientLimit unlimited
    ... fileCount -
    ... fileLimit unlimited
    ... repoCount -
    ... repoLimit unlimited
    ... licenseExpires 1582934400
    ... licenseTimeRemaining 5172009
    ... supportExpires 1582934400

If you want a warning that the license will expire within a specified amount of time, consider the script at https://swarm.workshop.perforce.com/files/guest/nick_poole/scripts/nagios/readme.txt.

### Limits for unlicensed use depend on the release

2019.2 patch 14, 2020.1 (patch 8), 2020.2 (patch 6), 2021.1 (patch 1), and later | 2016.1 and later but prior to 2019.2 patch 14, 2020.1 (patch 8), 2020.2 (patch 6), and 2021.1 (patch 1) | Prior to 2016.1
--- | --- | ---
Unlimited number of files for 5 users and 20 client workspaces, or Unlimited number of users and workspaces for up to 1,000 files | Unlimited number of files for 5 users and 20 client workspaces, or Unlimited number of users and workspaces for up to 1,000 files | Unlimited number of files for 20 users and 20 client workspaces, or Unlimited number of users and workspaces for up to 1,000 files
Three repos for Git Connector A component of P4 Server that enables you mirror, cache, or replicate a Git repository into a P4 Server repo in a graph depot. See also 'hybrid workspace'., which leverages the power and scale of P4 Server for large binary assets while allowing you to manage Git repos natively. |  |

## Options

Option | Description
--- | ---
`-o` | Display the current license file on the standard output if a valid license file is present in the P4 Server root directory, P4ROOT.
`-i` | Read in a new license file from the standard input. For example, see Adding or updating the license file.
`-u` | Report license limits, including the expiration of the license and of Support, and show how many entities (users or files) are in use with respect to these limits.
`-L` | Display valid server IP and MAC addresses to be used when requesting a valid license from Perforce Support.
`g-opts` | See Global options.

## Usage notes

Can File Arguments Use Revision Specifier? | Can File Arguments Use Revision Range? | Minimal Access Level Required
--- | --- | ---
N/A | N/A | super (`admin` for `-u` option)

## Examples

`p4 license -o` | Display the current license file on the standard output.
`p4 license -i` | Read in a new license file from the standard input.

Your search for returned results