Newer Version Available

This content describes an older version of this product. View Latest

config:unset (Deprecated)

Unsets the local and global configuration variables for the Salesforce CLI.

This command is deprecated. As of April 20, 2023, we no longer maintain this section of the command reference. Refer to the reference information about the sf-style commands instead, which we update regularly. We keep this reference information about the sfdx-style commands as-is for historical reference only.

Don't worry, this command and its flags continue to work the same as before, and any scripts that use the command won’t break. However, we recommend that you start using the equivalent sf-style config unset command instead. Here’s how the flags changed between the old and new commands; if a flag isn't listed, the old and new names are the same:

  • Removed flag: --loglevel. Use the SF_LOG_LEVEL environment variable instead.

For background information about this change, read this blog post, which describes how we've updated many of the existing sfdx commands to use the improvements we made in sf. We improved this particular command on March 9, 2023.

Warning

Help for config:unset

Local variables apply only to your current project. Global variables apply in any directory.

Examples for config:unset

1sfdx config:unset defaultusername defaultdevhubusername
1sfdx config:unset defaultdevhubusername -g

Command Syntax

sfdx config:unset
[--json]
[--loglevel LOGLEVEL]
[-g]

Parameters

--json
Optional

Format output as JSON.

Type: boolean
--loglevel LOGLEVEL
Optional

The logging level for this command invocation. Logs are stored in $HOME/.sf/sf.log.

Type: enum
Permissible values are: trace, debug, info, warn, error, fatal, TRACE, DEBUG, INFO, WARN, ERROR, FATAL
Default value: warn
-g | --global
Optional

Unsets the configuration variables globally, so they can be used from any directory.

Type: boolean

Aliases for config:unset

1force:config:unset