VSCode: Change Background Color of Unselected Occurrences

Viewed 428

When I select some content, VSCode automatically highlights other occurrences like this:

enter image description here

In the above example, the pass in line 2 is the selected one while others are automatically highlighted. This is a really nice feature, but the problem is, the background color of those unselected occurrences is too close to that of selections. How can I change the background color for those unselected occurrences?

1 Answers

The settings which will change backgorud is editor.selectionHighlightBackground. For changing background of highlighted similar words you should go to settings.json (CTRL+SHIFT+P -> type settings.json) of your theme and enter above code inside workbench.colorCustomizations.

"workbench.colorCustomizations":{
        "editor.selectionBackground": "#013c53",
        "editor.selectionHighlightBackground": "#ff0000"
}
Related