How to Fix Vim’s Ctrl+Q Not Working in the Visual Studio Code (VS Code) Terminal

The integrated terminal in VS Code is extremely convenient, and being able to use Vim as an extension of your daily coding workflow is a huge plus.
However, as you use it day-to-day, you might run into an issue where you think, “Wait, why isn’t Ctrl+Q working in Vim…?"

This happens because VS Code itself assigns its own custom shortcut to Ctrl+Q.
Since the VS Code shortcut takes priority, Ctrl+Q never reaches Vim inside the terminal.

In Vim, Ctrl+Q is frequently used for visual block mode (blockwise visual selection), and losing this functionality is surprisingly inconvenient.

目次

Objective of This Article

This guide explains how to get Vim’s Ctrl+Q working properly while still using VS Code.

Specifically, this is tailored for those who want to:

  • Avoid changing VS Code settings as much as possible
  • Ensure that only Vim inside the terminal works correctly

Here, we will introduce a safe and reliable way to configure this.

By changing these settings, you will achieve the following:

  • Vim inside the terminal will receive Ctrl+Q 100% of the time
  • The native VS Code Ctrl+Q shortcut will no longer interfere

In short, the goal is to reliably reproduce Vim’s visual block selection (Ctrl+Q) regardless of your environment.

Cause: Ctrl+Q Was Assigned to Two VS Code Commands

Upon checking the keybindings in VS Code, we found that Ctrl+Q was assigned to the following two commands:

  • workbench.action.quickOpenNavigateNextInViewPicker
  • workbench.action.quickOpenView

Both are internal commands related to Quick Open (view switching).
Because these commands react before the terminal can, Ctrl+Q fails to reach Vim.

Solution: Remove the Ctrl+Q Assignments in VS Code

Step 1: Open Keyboard Shortcuts Settings

  1. Press Ctrl + Shift + P
  2. Select “Preferences: Open Keyboard Shortcuts"
    → The keybindings list screen will open

Open Keyboard Shortcuts Settings

 

This method ensures you can open the shortcut list reliably.

Step 2: Search for “Ctrl+Q" and Remove the Two Assignments

Type Ctrl+Q into the search bar, and you will find the following two entries:

  • workbench.action.quickOpenNavigateNextInViewPicker
  • workbench.action.quickOpenView

 

Search for Ctrl + Q

Click the pencil icon (Edit Keybinding) on the far left of each.
Rebind them to a different key combination, such as Ctrl + Alt + Q.

Replaced with Ctrl + Alt + Q

Now VS Code will no longer react to Ctrl+Q, allowing Vim inside the terminal to receive Ctrl+Q properly.

Summary: Just Remove the Two Ctrl+Q Assignments in VS Code

The issue occurred because Ctrl+Q was reserved for two shortcuts on the VS Code side.

  • VS Code processes Ctrl+Q first
  • Vim becomes unable to receive the key input
  • Removing both assignments in the keyboard shortcuts screen resolves the issue

It’s a simple fix, but an easy blind spot to miss.
I hope this helps anyone struggling with the same problem.