ESP-IDF Settings
Visual Studio Code allows you to configure settings at different levels: Global (User Settings), Workspace and Workspace Folder. Ensure your project uses the correct settings.
Workspace folder configuration settings are defined in
${workspaceFolder}/.vscode/settings.jsonWorkspace configuration settings are defined in the workspace’s
<name>.code-workspacefileUser settings defined in
settings.jsonWindows:
%APPDATA%\Code\User\settings.jsonMacOS:
$HOME/Library/Application Support/Code/User/settings.jsonLinux:
$HOME/.config/Code/User/settings.json
This extension uses the idf.saveScope configuration setting (which can only be defined in User Settings) to specify where to save settings for features such as the Setup Wizard. You can modify this using the ESP-IDF: Select where to Save Configuration Settings command.
This extension contributes the following settings that can be later updated in settings.json or from VS Code Settings Preference Menu by:
Navigate to View > Command Palette.
Search for Preferences: Open User Settings (JSON), Preferences: Open Workspace Settings (JSON) or Preferences: Open Settings (UI) and select the command to open the setting management window.
Note
Please note that ~, %VARNAME% and $VARNAME are not recognized when set on ANY of this extension configuration settings. Instead, you can set any environment variable in the path using ${env:VARNAME}, such as ${env:HOME}, or refer to other configuration parameter path with ${config:SETTINGID}, such as ${config:idf.buildPath}.
Note
All settings can be applied to Global (User Settings), Workspace and WorkspaceFolder unless Scope is specified.
The settings are grouped in the same categories as in the VS Code Settings UI (and in package.json):
Setup & Installation
Setting ID |
Description |
|---|---|
idf.eimIdfJsonPath |
Path to the ESP-IDF Installation Manager (EIM) |
idf.eimExecutableArgs |
Arguments for the EIM executable (default: |
idf.currentSetup |
Current ESP-IDF setup identifier. Scope: Resource. |
idf.gitPath |
Path to the Git executable (default: |
idf.gitPathWin |
Path to the Git executable in Windows (default: |
idf.extensionActivationMode |
Controls extension activation mode: |
idf.gitPath (or idf.gitPathWin on Windows) is used by the extension to clone ESP-IDF or additional supported frameworks such as ESP-ADF, ESP-MDF and Arduino-ESP32.
Serial Port
Setting ID |
Description |
|---|---|
idf.port |
Path of selected device port (default: |
idf.portWin |
Path of selected device port in Windows (default: |
idf.monitorPort |
Optional path of selected device port for monitor. If undefined, idf.port is used. Scope: Resource. |
idf.flashBaudRate |
Flash baud rate (default: |
idf.monitorBaudRate |
Monitor baud rate. Empty by default to use sdkconfig |
idf.enableSerialPortChipIdRequest |
Enable detecting the chip ID and show on serial port selection list. Scope: Application. |
idf.useSerialPortVendorProductFilter |
Enable use of idf.usbSerialPortFilters to filter serial port devices list. Scope: Application. |
idf.usbSerialPortFilters |
USB productId and vendorId map to filter known Espressif devices. Scope: Application. |
idf.serialPortDetectionTimeout |
Timeout in seconds for serial port detection using esptool.py (default: 60). Scope: Resource. |
Flash
Setting ID |
Description |
|---|---|
idf.openOcdConfigs |
Configuration files for OpenOCD, relative to |
idf.flashType |
Preferred flash method: |
idf.flashPartitionToUse |
Partition to flash during build and flash (default: |
idf.jtagFlashCommandExtraArgs |
OpenOCD JTAG flash extra arguments (default: |
idf.preFlashTask |
Command string to execute before flash task. Scope: Resource. |
idf.postFlashTask |
Command string to execute after flash task. Scope: Resource. |
Note
When using ESP-IDF: Set Espressif Device Target, the extension overrides the current sdkconfig IDF_TARGET and updates idf.openOcdConfigs with default OpenOCD config files. To customize idf.openOcdConfigs only, use ESP-IDF: Select OpenOCD Board Configuration or edit settings.json.
Build
Setting ID |
Description |
|---|---|
idf.buildPath |
Custom build directory for extension commands (default: |
idf.buildPathWin |
Custom build directory in Windows (default: |
idf.cmakeCompilerArgs |
Arguments for CMake configuration (default includes |
idf.sdkconfigDefaults |
List of sdkconfig default values for initial build configuration. Scope: Resource. |
idf.ninjaArgs |
Arguments for Ninja build task. Scope: Resource. |
idf.customExtraVars |
Key-value object of environment variables added to extension command processes (e.g. |
idf.useIDFKconfigStyle |
Enable style validation for Kconfig files. Scope: Resource. |
idf.saveBeforeBuild |
Save all edited files before building (default: |
idf.enableCCache |
Enable CCache in build task (ensure CCache is in PATH). Scope: Resource. |
idf.extraCleanPaths |
Additional paths to delete on Full Clean Project (default: |
idf.sdkconfigFilePath |
Absolute path for the sdkconfig file. Scope: Resource. |
idf.enableSizeTaskAfterBuildTask |
Run IDF Size task after IDF Build task (default: |
idf.preBuildTask |
Command string to execute before build task. Scope: Resource. |
idf.postBuildTask |
Command string to execute after build task. Scope: Resource. |
Debug & OpenOCD
Setting ID |
Description |
|---|---|
openocd.tcl.host |
OpenOCD TCL server host (default: |
openocd.tcl.port |
OpenOCD TCL server port (default: |
openocd.jtag.command.force_unix_path_separator |
Use |
idf.launchMonitorOnDebugSession |
Launch ESP-IDF Monitor when starting an ESP-IDF debug session (default: |
idf.openOcdDebugLevel |
OpenOCD debug level 0–4 (default: 2). 0 = error only, 4 = verbose. Ignored if idf.openOcdLaunchArgs is set. Scope: Resource. |
idf.openOcdLaunchArgs |
Custom arguments for OpenOCD. If set, idf.openOcdConfigs and idf.openOcdDebugLevel are ignored. Command form otherwise: |
idf.svdFilePath |
SVD file path for chip debug peripheral tree view (default: |
Monitor
Setting ID |
Description |
|---|---|
idf.monitorDelay |
Delay in milliseconds before starting debug session after IDF Monitor or when breaking monitor (default: 1000). Scope: Resource. |
idf.monitorNoReset |
Enable no-reset flag for IDF Monitor (default: |
idf.monitorEnableTimestamps |
Enable timestamps in IDF Monitor (default: |
idf.monitorCustomTimestampFormat |
Custom timestamp format for IDF Monitor. Scope: Resource. |
App Trace
Setting ID |
Description |
|---|---|
trace.poll_period |
Poll period for apptrace. Scope: Resource. |
trace.trace_size |
Trace size for apptrace (default: 2048). Scope: Resource. |
trace.stop_tmo |
Stop timeout for apptrace (default: 3). Scope: Resource. |
trace.wait4halt |
Wait for halt for apptrace (0 or 1, default: 0). Scope: Resource. |
trace.skip_size |
Skip size for apptrace (default: 0). Scope: Resource. |
Tasks & Terminal
Setting ID |
Description |
|---|---|
idf.customTask |
Custom task command for ESP-IDF: Execute Custom Task. Scope: Resource. |
idf.customTerminalExecutable |
Absolute path to shell executable for extension terminals (default: VS Code default). Scope: Resource. |
idf.customTerminalExecutableArgs |
Arguments for idf.customTerminalExecutable. Scope: Resource. |
UI & Notifications
Setting ID |
Description |
|---|---|
idf.showOnboardingOnInit |
Show ESP-IDF configuration/onboarding window on extension activation (default: |
idf.hasWalkthroughBeenShown |
Whether the walkthrough has been shown. Scope: Application. |
idf.notificationMode |
Notifications and output focus mode: |
idf.saveScope |
Where to save extension settings: Global (1), Workspace (2), WorkspaceFolder (3). Scope: Application only. |
idf.enableStatusBar |
Show or hide extension status bar items (default: |
idf.enableUpdateSrcsToCMakeListsFile |
Enable updating source files in |
Telemetry
Setting ID |
Description |
|---|---|
idf.telemetry |
Enable telemetry (default: |
ESP Rainmaker Settings
Setting ID |
Description |
|---|---|
esp.rainmaker.api.server_url |
ESP Rainmaker API server URL (default: |
esp.rainmaker.oauth.url |
ESP Rainmaker OAuth URL (default: |
Coverage
Setting ID |
Description |
|---|---|
idf.coveredLightTheme |
Background color for covered lines (light theme) in gcov coverage (default: |
idf.coveredDarkTheme |
Background color for covered lines (dark theme) in gcov coverage (default: |
idf.partialLightTheme |
Background color for partially covered lines (light theme) (default: |
idf.partialDarkTheme |
Background color for partially covered lines (dark theme) (default: |
idf.uncoveredLightTheme |
Background color for uncovered lines (light theme) (default: |
idf.uncoveredDarkTheme |
Background color for uncovered lines (dark theme) (default: |
Component Manager
Setting ID |
Description |
|---|---|
idf.enableIdfComponentManager |
Enable IDF Component Manager in build command (default: |
esp.component-manager.url |
ESP Component Registry URL (default: |
QEMU Settings
Setting ID |
Description |
|---|---|
idf.qemuDebugMonitor |
Enable QEMU Monitor in debug session (default: |
idf.qemuExtraArgs |
Extra arguments for QEMU. Scope: Resource. |
Unit Test
Setting ID |
Description |
|---|---|
idf.unitTestFilePattern |
Glob pattern for unit test file discovery (default: |
Other
Setting ID |
Description |
|---|---|
idf.wssPort |
WebSocket server port (default: 49203, range 49152–65535). Scope: Resource. |
idf.sbomFilePath |
Path for ESP-IDF SBOM report (default: |
idf.imageViewerConfigs |
Path to custom image format configurations JSON for the Image Viewer (relative to workspace or absolute). Scope: Resource. |
Use of Environment Variables in ESP-IDF settings.json and using other ESP-IDF settings within ESP-IDF settings
Environment (env) variables and other ESP-IDF settings (config) can be referenced in ESP-IDF settings using the syntax ${env:VARNAME} and ${config:ESPIDFSETTING}, respectively.
You can also prepend a string to the result of the other ESP-IDF settings (config) by using the syntax ${config:ESPIDFSETTING,prefix}. The prefix will be added directly to the beginning of each string value. For example ${config:idf.openOcdConfigs,-f} will add -f to the beginning of each string value of idf.openOcdConfigs.
If "idf.openOcdConfigs": ["interface/some.cfg", "target/some.cfg"] the expansion will be -finterface/some.cfg -ftarget/some.cfg.
For example, to use "~/workspace/blink", set the value to "${env:HOME}/workspace/blink".