This document lists the configurable settings for VS Code Extension.
Configure Settings
To configure VS Code Extension settings:
Settings
The following table lists the available settings for VS Code Extension:
Setting | Description | Default | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
Shell | MongoDB shell to use. Choose either:
To launch your selected MongoDB shell, you must:
If you install a new version of your MongoDB shell, you will need to
update your
|
| ||||||||
Show | If enabled, shows the MongoDB view in the Visual Studio Code left navigation panel. | Enabled | ||||||||
Max Number of Problems | The maximum number of problems VS Code Extension will generate in the Visual Studio Code Problems view. |
| ||||||||
Trace: Server | MongoDB language server logging settings. Edit this setting through the
Within the
Output logs are viewable by selecting MongoDB Language Server from the dropdown in the Output view, or with the Language Server Protocol Inspector. |
| ||||||||
Confirm Run All | If enabled, shows a confirmation message before running commands in a playground. | Enabled | ||||||||
Default Connection Saving Location | Sets if and where new connections are saved. You can select:
|
| ||||||||
Hide Option To Choose Where To Save New Connections | If disabled, you are prompted to choose where to save each new connection. If enabled, new connections are automatically saved to the Default Connection Saving Location without prompt. | Enabled | ||||||||
Default Limit | Number of documents to fetch when viewing documents from a collection. Does not affect playground operations. |
| ||||||||
Preset Connections | Specifies a preset list of connections. Use this setting to share connection configurations in a workspace or global scope. Edit the Within the
WARNING: Do not store sensitive credentials in this setting. Connection strings are stored in plain text, so they can be easily accessed. |
| ||||||||
Send Telemetry | If enabled, allows the collection of anonymous diagnostic and usage telemetry data to help improve VS Code Extension. | Enabled | ||||||||
Use Default Template For Playground | If enabled, playground files load with a template containing sample commands. If disabled, playground files load with an empty playground editor. | Enabled | ||||||||
MCP: Server | Controls whether the MongoDB MCP server starts automatically when VS Code opens and connects to the active connection.
NoteThe first time the server starts automatically, VS Code displays a notification asking if you want to keep this behavior. Your choice automatically updates this setting. When the MCP server is not running, use the MongoDB: Start MCP Server command to start the MCP server immediately. |
| ||||||||
MCP: Api Base URL | If you're using a custom Atlas deployment, specify the API URL used by the MongoDB MCP server that enables Atlas MCP tools. |
| ||||||||
MCP: Api Client ID | Atlas API client ID for authenticating against the Atlas API. Use a Service Account for programmatic access to Atlas APIs. Required for enabling Atlas tools in MongoDB MCP server. Store your ID securely and do not commit it to version control. To learn more, see Connecting with Atlas API Credentials. | Empty | ||||||||
MCP: Api Client Secret | Atlas API client secret for authenticating against the Atlas API. Use a Service Account for programmatic access to Atlas APIs. Required for enabling Atlas tools in MongoDB MCP server. Store this securely and do not commit to version control. To learn more, see Connecting with Atlas API Credentials. | Empty | ||||||||
MCP: Disabled Tools | Tool names, operation types ( | Empty | ||||||||
MCP Export Cleanup Interval Ms | How often (in milliseconds) the MongoDB MCP server runs the export cleanup process to remove expired files. Default is 2 minutes (120000ms). |
| ||||||||
MCP Exports Path | The directory where the MongoDB MCP server exports data when using the export tool. Ensure that the path is available for writes or leave this setting empty to use the default path based on your operating system. Default paths:
| Empty | ||||||||
MCP Export Timeout Ms | The maximum time in milliseconds an export operation can run before MongoDB MCP server terminates it. Default is 5 minutes (300000ms). |
| ||||||||
MCP Index Check | When enabled, the MongoDB MCP server enforces that query operations must use an index, and rejects queries that perform a collection scan. This helps prevent performance issues in production environments. | Disabled | ||||||||
MCP: Read Only | When enabled, the MongoDB MCP server only allows read, connect, and metadata operation types. Create, update, and delete operations are disabled. | Disabled |