Skip to main content

1Password CLI environment variables

You can use the following environment variables with 1Password CLI:

Environment variableDescription
OP_ACCOUNTSpecifies a default 1Password account to execute commands. Accepts an account sign-in address or ID. An account specified with the --account flag takes precedence.
OP_BIOMETRIC_UNLOCK_ENABLEDToggles the 1Password app integration on or off. Options: true, false.
OP_CACHEToggles the option to store and use cached information on or off. Options: true, false. Default: true.
OP_CONFIG_DIRSpecifies a configuration directory to read and write to. A directory specified with the --config flag takes precedence.
OP_CONNECT_HOSTSets a Connect server instance host URL to use with 1Password CLI.
OP_CONNECT_TOKENSets a Connect server token to use with 1Password CLI.
OP_DEBUGToggles debug mode on or off. Options: true, false. Default: false.
OP_FORMATSets the output format for 1Password CLI commands. Options: human-readable, json. Default: human-readable.
OP_INCLUDE_ARCHIVEAllows items in the archive to be retrieved with op item get and op document get commands. Options: true, false. Default: false.
OP_ISO_TIMESTAMPSToggles the option to format timestamps according to ISO 8601 and RFC 3339 standards on or off. Options: true, false. Default: false.
OP_RUN_NO_MASKINGToggles masking off for the output of op run.
OP_SESSIONStores a session token when you sign in to 1Password CLI manually.
OP_SERVICE_ACCOUNT_TOKENConfigures 1Password CLI to authenticate with a service account.

Was this page helpful?