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

P4 CLI Documentation | 2025.2

# p4 remote

Create, modify or delete a remote specification.

For distributed version control. See P4 Server Administration Documentation (DVCS).

## Syntax

    p4 [g-opts] remote [-f] remoteID
    p4 [g-opts] remote -d [-f] remoteID
    p4 [g-opts] remote -o remoteID
    p4 [g-opts] remote -i [-f]

Syntax and naming conventions

## Description

(DVCS) A remote describes the shared server that your server cooperates with. The `p4 remote` command lets you configure your system to use the p4 fetch and p4 pull commands to copy work between your server and the shared server. A remote specification describes the high level configuration and usage of a remote. The `p4 remote` command allows you to create, modify, or delete a remote specification.

A DVCS remote shared server is not related to the concept of a remote depot in the P4 Server Administration Documentation.

The `p4 remote` command puts the remote specification (spec) into a temporary file and invokes the editor configured by the `P4EDITOR` environment variable. Saving the file creates or modifies the remote spec.

## Form fields

Field Name | Type | Description
--- | --- | ---
RemoteID: | mandatory | The identifier of the remote. This is set from the command line and cannot be changed. For example, `p4 remote -o test-remote1`
Address: | mandatory | The `P4PORT` that is used by the server.
Owner: | optional | The user who created this remote spec. Can be changed. The specified owner does not have to be a P4 Server user. You might want to use an arbitrary name if the user does not yet exist, or if you have deleted the user and need a placeholder until you can assign the spec to a new user.
RemoteUser: | optional | Specifies the identity (user) P4 Server uses to authenticate against this remote server when pushing and fetching. Can be changed. The RemoteUser setting can by overridden by using the `--remote-user` option of p4 push, p4 fetch, or p4 login.
Update: | read-only | The date and time this remote spec was last modified.
Access | read-only | The last time this remote was used to fetch or push.
Description: | optional | A description of the remote spec.
Options: | optional | Flags to change the remote spec behavior. The defaults are marked with `*`. `locked/*unlocked` Permits only the owner to change the remote, and prevents the remote spec from being deleted. `compress/*nocompress` Compresses data sent between the local and remote server to speed up slow connections. `*copyrcs/nocopyrcs` During a `p4 fetch` or `p4 push`, transfers entire Revision Control System (RCS) archive files Versioned files that users submitted to a depot. when possible, or never transfers entire RCS archive files. By default, `p4 fetch` and `p4 push` copy RCS archive files from and to the shared server as a unit, retrieving multiple revisions with a single file transfer. Sometimes, this optimization is undesirable, because when entire RCS archive files are copies, the archive change numbers are copied as well. This can cause your personal server to experience a "jump" in changelist numbers when changes are fetched from or pushed to the shared server.
LastFetch: | read-only | The last changelist that was fetched.
LastPush: | read-only | The last changelist that was pushed.
DepotMap: | optional | Mapping between the local and remote files.
ArchiveLimits: | optional | One or more entries specifying how many revisions of file archives to store locally when the files are fetched. See the P4 Server Administration Documentation topics on: ArchiveLimits: entries, which shows an example of ArchiveLimits referencing the local (receiving) server path. Configure server to limit storage of archive revisions.
`RemoteCharset`: | optional | (2025.2 and later) The charset for fetching from a non-unicode mode server to a unicode mode server. This charset is used to convert the non-unicode mode server's text data into UTF8. The local machine performs the conversion by using the remote specification for the remote server. If the `RemoteCharset` field is set to `utf8`, no translation is performed. Instead, a check occurs to ensure there are no invalid UTF-8 sequences. To learn more, see Prerequisites between servers in theP4 Server Administration Documentation.

## Options

With no options specified, `p4 remote` invokes your editor for the specified remote spec.

Option | Description
--- | ---
`-d remote` | Deletes the named remote.
`-f` | Enables a user with admin privileges to delete the spec or set the last modified date. By default, specs can be deleted only by their owner.
`-i` | Causes a remote spec to be read from the standard input. The user’s editor is not invoked.
`-o remote` | Writes the remote spec for the named remote to standard output. The user’s editor is not invoked.

## Usage notes

Can File Arguments Use Revision Specifier? | Can File Arguments Use Revision Range? | Minimal Access Level Required
--- | --- | ---
N/A | N/A | open, or `list` to use the `-o` option or `admin` to use the `-f` option

## Examples

`p4 remote -i` | Read in a remote spec from standard input.

## Related commands

To display a list of remote specifications | `p4 remotes`

Your search for returned results