How to use voice typing in VS Code: built-in speech and system-wide dictation
Set up private voice typing in VS Code with Microsoft's local Speech extension or a system-wide Mac dictation app, then use it safely for chat, comments, and code.

Answer first
The short answer
Install Microsoft's VS Code Speech extension, run “Voice: Start Dictation in Editor,” and stop with Escape to get private local editor dictation without an online speech service. Use “Chat: Start Voice Chat” for AI chat and hold the shortcut for walky-talky behavior. If you need the same vocabulary, history, local model choice, or code-aware formatting outside VS Code, add a system-wide Mac tool such as VoiceGem. Keep the editor-native and global shortcuts distinct so one recording method never triggers the other.
Best-fit verdict
VS Code Speech should be the first test for anyone whose voice workflow stays inside VS Code: it is official, local, focused, and free. Add VoiceGem when you need cross-app input, model choice, custom modes, vocabulary, replacements, or spoken identifier formatting. Neither option makes dictated code trustworthy without formatting, diagnostics, tests, and review.
VS Code voice input methods
| Method | Best for | Tradeoff |
|---|---|---|
| VS Code Speech: editor dictation | Prose, comments, commit input, and review fields inside VS Code | Limited to supported editor surfaces and 26 documented languages |
| VS Code Speech: voice chat | Speaking prompts directly to VS Code chat | Pause-to-submit behavior needs careful timeout configuration |
| VoiceGem system-wide mode | Same local workflow across VS Code, Cursor, browser, email, and terminal | Requires macOS microphone and Accessibility permissions |
| Apple Dictation | Built-in occasional prose input | Fewer developer-specific modes and vocabulary controls |
| Cloud voice service | Managed cleanup or a language/model that local options handle poorly | External processing and service availability |
Does VS Code have built-in voice typing?
VS Code has official voice support through the Microsoft VS Code Speech extension. The documentation says recognition is computed locally and recordings are never sent to an online service. Once installed, the extension adds editor dictation, voice chat, walky-talky shortcuts, optional keyword activation, and text-to-speech. It supports 26 languages through the accessibility voice language setting.
Editor dictation is not limited to source files. Microsoft explicitly documents rich editor surfaces such as the source-control commit input and pull-request review comments. That makes it a useful low-risk tool for developer prose. Voice chat can open inline or in the Chat view and can automatically submit after a pause; adjust the speech timeout or disable automatic submission if you need a review step.
How do you start and stop VS Code dictation?
After installing the Speech extension, open the Command Palette and run “Voice: Start Dictation in Editor.” On macOS, the documented default shortcut is Option-Command-V. Escape stops recognition. Holding the start shortcut enables walky-talky behavior: recognition remains active while the keys are held and stops on release. If the shortcut conflicts with your setup, remap it through Keyboard Shortcuts.
For chat, run “Chat: Start Voice Chat” or use Command-I on macOS according to the current documentation. Confirm where focus is before speaking because VS Code can open chat in different locations. Set `accessibility.voice.speechTimeout` to control how long a pause waits before submission, or set it to zero when you always want to review a prompt before sending.
- Use editor dictation for text you want to inspect without automatic submission.
- Use walky-talky mode for short comments or prompts when holding a chord is comfortable.
- Avoid keyword activation in shared spaces or around sensitive conversations unless its always-listening behavior fits your policy.
When should you add VoiceGem to VS Code?
VS Code Speech is intentionally editor-focused. VoiceGem adds a consistent global shortcut across VS Code, Cursor, Windsurf, browsers, issue trackers, email, and chat applications. It can select local speech models, maintain vocabulary and replacements, trigger modes by active application, and translate spoken symbol or casing commands through Developer Mode.
That broader integration requires more trust. A system-wide app needs microphone access and may need Accessibility permission to insert text into other applications. Apple warns that Accessibility access is powerful and should be granted only to familiar software. Keep VS Code Speech as a lower-permission option when it solves the task, and use system-wide input where cross-app consistency genuinely reduces work.
Can you dictate code accurately in VS Code?
You can dictate source-like text, but literal speech recognition is optimized for language, not a programming grammar. Common punctuation may arrive, yet identifiers, operators, indentation, generics, regular expressions, and shell syntax remain difficult. A developer formatter can interpret explicit commands such as casing and brackets, but ambiguity remains. The safest units are names, comments, tests, repetitive declarations, and compact expressions.
For larger changes, dictate a detailed prompt into chat. State the objective, relevant files, constraints, expected behavior, tests, and non-goals. Review the transcript before submission, then review the generated diff. Format, type-check, lint, and test. Voice can increase the amount of useful context you provide; deterministic tooling still decides whether the code is acceptable.
How do you troubleshoot voice typing in VS Code?
If no microphone appears, confirm the VS Code Speech extension is installed and the command exists, then review macOS Microphone permission for VS Code. If the wrong language is recognized, set `accessibility.voice.speechLanguage` and allow the matching language extension to install. If chat submits too quickly, increase or disable the speech timeout. If a global app records but does not paste, review its Accessibility permission and target focus.
If technical terms fail, add vocabulary in the system-wide tool or simplify repeated names through deterministic replacements. VS Code Speech's documented feature set does not promise a project dictionary. If recognition works but code is malformed, separate speech errors from formatting errors: first capture literal text, then apply a code-aware mode only where needed. This makes debugging the pipeline possible.
Action plan
Step-by-step: enable private voice typing in VS Code
Begin with the official local extension. Add a system-wide app only after you can name the extra cross-app or formatting capability you need.
- 1
Install VS Code Speech
Open Extensions, install the Microsoft VS Code Speech extension, and allow its language component to install when first used.
- 2
Grant microphone permission
When macOS asks, allow VS Code to use the microphone. Review the setting later under Privacy & Security → Microphone.
- 3
Start editor dictation
Focus a safe text field and run Voice: Start Dictation in Editor or use Option-Command-V on macOS. Press Escape to stop.
- 4
Configure language and timeout
Set accessibility.voice.speechLanguage and, for chat, adjust accessibility.voice.speechTimeout so prompts are not submitted before review.
- 5
Test developer fields
Try a comment, commit message, review note, chat prompt, and small source fragment. Record which tasks need specialist formatting.
- 6
Add system-wide dictation if needed
Configure VoiceGem with a separate shortcut and local model for input across apps, vocabulary, modes, and developer notation.
- 7
Verify code normally
Run formatters, diagnostics, type checks, lint, tests, and diff review after source-like dictation or agent changes.
Limitations and tradeoffs
- Microsoft officially supports VS Code Speech in VS Code. Cursor and other VS Code-derived editors can differ in extension compatibility and should be tested separately.
- The documented language set is 26, which is narrower than some general-purpose speech products. Recognition quality still varies across language, microphone, and vocabulary.
- Local editor recognition does not make AI chat local. The selected chat or agent provider has its own data-processing path after the transcript is submitted.
Frequently asked questions
Is VS Code Speech free?
The Microsoft VS Code Speech extension is available as part of the VS Code ecosystem and its official documentation does not require a separate speech service subscription.
Does VS Code voice typing send audio to the cloud?
Microsoft says voice support does not require being online and recordings are computed locally rather than sent to an online service.
What is the Mac shortcut for editor dictation?
The current official default is Option-Command-V to start editor dictation and Escape to stop. Keybindings can be remapped.
Can I use voice in VS Code chat?
Yes. VS Code documents Chat: Start Voice Chat and location-specific voice-chat commands, with a configurable pause-to-submit timeout.
Why add VoiceGem if VS Code already has speech?
VoiceGem adds consistent input across other apps, local model choice, history, vocabulary, modes, replacements, and developer-specific symbol and casing formatting.
Can voice typing execute code accidentally?
Editor dictation inserts text, but voice chat or terminal workflows can lead to execution. Keep submission and execution explicit, review prompts and commands, and disable unsafe auto-run behavior.
Primary sources reviewed
Product capabilities, plans, and policies change. These first-party sources were reviewed on July 18, 2026 so you can verify the current details before deciding.
- VS Code voice support
Microsoft's official source for installation, local processing, editor dictation, voice chat, shortcuts, timeouts, keyword activation, and languages.
- Apple microphone permissions
Primary instructions for granting, reviewing, and revoking microphone access on macOS.
- Apple Accessibility permissions
Primary guidance for the additional permission a system-wide cursor tool may need.
- VoiceGem source repository
Current source and documentation for the optional system-wide local model, modes, vocabulary, and developer formatter.
- Cursor keyboard shortcuts
Official reference for readers adapting the workflow to Cursor and checking conflicts.