How to Disable/Enable hover hints (tooltips) in VS Code

avatar
Borislav Hadzhiev

Last updated: Apr 6, 2024
4 min

banner

# Table of Contents

  1. How to Disable/Enable hover hints (tooltips) in VS Code
  2. Disabling hover hints with a more fine-grained approach
  3. Only disabling hover hints for the current project
  4. Alternatively, you can increase the hover delay

# How to Disable/Enable hover hints (tooltips) in VS Code

The default behavior in VS Code is for additional information (tooltips) to show every time you hover over a symbol.

vscode hover hints

You can disable or enable hover hints (tooltips) directly in the settings UI:

  1. Press Ctrl + Shift + P (or Command + Shift + P on macOS).
Note: you can also press F1 to open the Command Palette.
  1. Type user settings and select Preferences: Open User Settings.

open user settings

You can also open the settings screen by pressing Ctrl + , on Windows and Linux or Cmd + , on macOS.

  1. Search for hover enable and uncheck the checkbox to disable hover hints.

disable tooltips

Once tooltips are disabled you will no longer get pop-ups when you hover over a symbol.

hover hints disabled

When the Editor Hover: Enabled checkbox is checked, the editor shows additional information on hover.

When the checkbox is unchecked, no information on hover is shown.

If you disable hover suggestions, you can still show a pop-up with additional information about the symbol using a keyboard shortcut.

On Windows and Linux:

  1. Move your cursor to the symbol.

  2. Press Ctrl + K, release the keys and then press Ctrl + I

On macOS:

  1. Move your cursor to the symbol.

  2. Press Cmd + K, release the keys and then press Cmd + I.

show hover hints with keyboard shortcut

You can view the default keyboard shortcut for the Show Hover command in this table in the docs.

You can press the Esc key to hide the pop-up.

# Disabling hover hints with a more fine-grained approach

You can also update the setting directly in your settings.json file.

  1. Press Ctrl + Shift + P (or Command + Shift + P on macOS).
Note: you can also press F1 to open the Command Palette.
  1. Type user settings json.

  2. Click on Preferences: Open User Settings (JSON)

preferences open user settings

  1. Set the following property.
settings.json
"editor.hover.enabled": false,

If the property comes last, remove the trailing comma.

disable hover hints settings json

You can disable tooltips using more fine-grained settings.

setings.json
"editor.parameterHints.enabled": false, "editor.suggest.snippetsPreventQuickSuggestions": false, "editor.snippetSuggestions": "none", "html.suggest.html5": false
  • editor.parameterHints.enabled - enables a pop-up that shows parameter documentation and type information as you type.
  • editor.suggest.snippetsPreventQuickSuggestions - controls whether an active snippet prevents quick suggestions.
  • editor.snippetSuggestions - controls whether snippets are shown with other suggestions and how they are sorted.
  • html.suggest.html5 - controls whether the built-in HTML language support suggests HTML5 tags, properties and values.

# Only disabling hover hints for the current project

If you only need to disable tooltips for the current project and not globally (for all projects of the user), create a .vscode/settings.json file.

  1. In the root directory of your project, create a .vscode folder.

  2. Create a settings.json file in the .vscode folder.

  3. Add the following code to your settings.json file.

.vscode/settings.json
{ "editor.hover.enabled": false }

disable hover hints for current project

The configuration in your local .vscode/settings.json file only applies to the current project and overrides any global configuration.

# Alternatively, you can increase the hover delay

There is also a hover delay setting that controls the delay in milliseconds after which the hover is shown.

You could leave the hover hints enabled but increase the delay.

  1. Press Ctrl + Shift + P (or Command + Shift + P on macOS).
Note: you can also press F1 to open the Command Palette.
  1. Type user settings and select Preferences: Open User Settings.

open user settings

You can also open the settings screen by pressing Ctrl + , on Windows and Linux or Cmd + , on macOS.

  1. Search for editor hover and scroll down to the Editor Hover: Delay setting.

editor hover delay setting

The setting controls the delay in milliseconds after which the hover is shown.

The default value is for hover hints to show after 300 milliseconds.

You could set the delay to 1000 milliseconds (1 second).

Here is a short clip that demonstrates the difference.

hover hints with delay

If you decide to use the Editor Hover: Delay setting, make sure the editor.hover.enabled setting is set to true.

If hints are disabled, the hover delay setting has no effect.

I've also written an article on how to disable references (CodeLens) in VS Code.

# Additional Resources

You can learn more about the related topics by checking out the following tutorials:

I wrote a book in which I share everything I know about how to become a better, more efficient programmer.
book cover
You can use the search field on my Home Page to filter through all of my articles.