Skip to main content

cli config reset

Resets the specified CLI configuration option to its default value


m365 cli config reset [options]


-k, --key [key]

Config key to reset. If not specified, will reset all configuration settings to default

-h, --help [help]

Output usage information. Optionally, specify which section of command's help you want to see. Allowed values are options, examples, remarks, response, full. Default is full.

--query [query]

JMESPath query string. See for more information and examples.

-o, --output [output]

Output type. json, text, csv, md. Default json.


Runs command with verbose logging.


Runs command with debug logging.

Available settings

Following is the list of configuration settings available in CLI for Microsoft 365.

Setting nameDefinitionDefault value
autoOpenLinksInBrowserAutomatically open the browser for all commands which return a url and expect the user to copy paste this to the browser. For example when logging in, using m365 login in device code mode.false
copyDeviceCodeToClipboardAutomatically copy the device code to the clipboard when running m365 login command in device code modefalse
csvEscapeSingle character used for escaping; only apply to characters matching the quote and the escape options"
csvHeaderDisplay the column names on the first linetrue
csvQuoteThe quote characters surrounding a field. An empty quote value will preserve the original field, whether it contains quotation marks or not.
csvQuotedQuote all the non-empty fields even if not requiredfalse
csvQuotedEmptyQuote empty strings and overrides quoted_string on empty strings when definedfalse
disableTelemetryDisables sending of telemetry datafalse
errorOutputDefines if errors should be written to stdout or stderrstderr
helpModeDefines what part of command's help to display. Allowed values are options, examples, remarks, response, fullfull
interactiveEnables interactive selection when multiple values are available for a command that requires a specific value to be retrieved.false
outputDefines the default output when issuing a commandjson
printErrorsAsPlainTextWhen output mode is set to json, print error messages as plain-text rather than JSONtrue
promptPrompts for missing values in required optionsfalse
showHelpOnFailureAutomatically display help when executing a command failedtrue
showSpinnerDisplay spinner when executing commandstrue


Reset CLI configuration option showHelpOnFailure to its default value

m365 cli config reset --key showHelpOnFailure

Reset all configuration settings to default

m365 cli config reset


The command won't return a response on success.

More information