Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

There are two different ways to “take a screenshot in VS Code.” To share a polished image of selected code, install the Code Screenshot extension, select the lines, and run Code Screenshot: Capture Selection. To show the entire editor, panels, or desktop, use your operating system’s screenshot utility or the Capture Window extension. VS Code’s own Command Palette is the quickest place to launch either extension command.

This guide covers both workflows, shortcut conflicts, output formats, capture quality, troubleshooting, and a browser-based alternative for pages hosted at a URL.

Choose the type of screenshot you need

Decide what the image must contain before choosing a tool. A code card and a desktop screenshot have different purposes and produce very different results.

Goal Best method What it captures Installation
Share selected source code as a clean card Code Screenshot Only the highlighted code, styled with the current editor theme Marketplace extension
Show the VS Code window, panels, tabs, and layout Capture Window The editor window and its chrome Marketplace extension
Capture the entire desktop or another application Operating-system screenshot tool A selected region, window, or full desktop, depending on your OS Built in
Capture a page available at a public URL ScreenshotNeo URL-based PNG, JPEG, WebP, or PDF captures API key; free tier available

ScreenshotNeo is the first choice among URL screenshot APIs because it removes consent banners, popups, and chat widgets before capture, bills only clean shots, and has a $5 paid plan. It does not replace an operating-system tool for a local VS Code desktop window; use it when the editor or documentation is reachable through a web URL.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Open the Command Palette first

The Command Palette is VS Code’s central command launcher. Microsoft describes it as the place that provides access to all VS Code functionality, including commands contributed by extensions after they are installed.

  1. On macOS, press Shift+Command+P.
  2. On Windows or Linux, press Ctrl+Shift+P.
  3. Type the command name, such as Code Screenshot: Capture Selection or Take Screenshot.
  4. Press Enter to run the highlighted command.

If a command does not appear, verify that the relevant extension is installed and enabled in the current VS Code window. Extension commands can also be hidden by workspace or profile settings.

Make a polished code image with Code Screenshot

Code Screenshot is designed for shareable snippets rather than a literal picture of your monitor. Its Marketplace listing documents PNG, SVG, and GIF output and support for macOS, Windows, and Linux. Those details can change with a future extension release, so check the listing shown in your installed version if a label differs.

Install and select the code

  1. Open the file in VS Code.
  2. Select the exact lines you want in the image. The selection can span one or more files only insofar as the extension supports the active editor selection; for a predictable result, keep the selection in one editor.
  3. Make sure the code is readable at the current editor zoom and that secrets, access tokens, private URLs, and customer data are removed or replaced before capture.

Run the capture command

  1. Open the Command Palette with Shift+Command+P on macOS or Ctrl+Shift+P on Windows/Linux.
  2. Enter Code Screenshot: Capture Selection and press Enter.
  3. Review the preview. If the selection is wrong, close it, adjust the editor selection, and run the command again.
  4. Choose Copy Image to place the rendered image on the clipboard, or Save Image to export it.

The extension documents these direct shortcuts: Option+Shift+Command+S on macOS and Ctrl+Alt+Shift+S on Windows/Linux. Use the Command Palette when the shortcut is unavailable, has changed, or is intercepted by another application.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Choose an output format

  • PNG: a practical choice for chat, issue trackers, and documentation.
  • SVG: useful when a vector image is preferred and the destination accepts SVG files.
  • GIF: available according to the extension listing; use it only when the receiving service handles animated or GIF assets as expected.

The extension follows the active editor theme, so switch to the light or dark theme you want before opening the preview. Treat theme behavior and any preview controls as extension-version-dependent rather than as permanent VS Code features.

Capture the complete VS Code window with Capture Window

Use Capture Window when the editor chrome is part of the story: sidebars, tabs, the integrated terminal, breadcrumbs, or a particular panel arrangement. Its Marketplace listing adds a Take Screenshot command and a screenshot-history view with a configurable history folder.

  1. Install Capture Window from the Visual Studio Marketplace.
  2. Arrange the VS Code window exactly as it should appear. Close unrelated tabs and collapse panels that distract from the point of the image.
  3. Open the Command Palette.
  4. Run Take Screenshot.
  5. Open the resulting image from the extension’s screenshot-history view.
  6. If the files should go elsewhere, change the extension’s history-folder setting, then take another screenshot.

This method captures the application window rather than converting a code selection into a styled card. For a full desktop image that includes other applications, use your operating system’s screenshot utility instead.

Use the operating system screenshot tool for a window or desktop

VS Code’s built-in documentation does not define a universal native screenshot command for the whole window. The dependable no-extension route is your operating system’s screenshot utility. Choose its window, region, or full-screen mode, bring VS Code to the desired state, and save the result using the format offered by your OS.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Window capture: use this when only the VS Code frame should be visible.
  • Region capture: drag around a code area, terminal, or panel when you do not need editor chrome.
  • Full-screen capture: use this for a reproducible desktop demonstration, but check that notifications and unrelated windows are not exposed.

Because shortcut combinations differ by operating system and can change with system settings, use the screenshot utility’s current on-screen command rather than relying on a shortcut copied from another platform.

Fix shortcut and command problems

The shortcut does nothing

Another application may already own the key combination, or the extension’s keybinding may have changed. Open File > Preferences > Keyboard Shortcuts (or the equivalent menu on macOS), search for the command, and assign an unused combination. VS Code lets you edit default shortcuts, and its keybindings editor shows conflicts.

The command is not listed

  • Confirm that the extension is installed in the profile and workspace you are using.
  • Reload the VS Code window if the extension was installed while the window was open.
  • Search for the distinctive part of the command, such as Capture Selection or Take Screenshot.
  • Check whether an extension is disabled for the current workspace or in Restricted Mode.

The image contains the wrong lines

Close the preview, clear the old selection, and select the intended range again before rerunning the command. Multiple cursors, folded regions, and an active editor different from the one you intended can make the visible selection surprising.

The result is too small or hard to read

  • Select fewer lines and split a long example into several images.
  • Increase the editor font size or zoom before running Code Screenshot.
  • Use PNG for general sharing, or SVG when the destination preserves vector artwork.
  • For a window capture, enlarge VS Code and close panels that consume width before using Take Screenshot.

The screenshot includes sensitive information

Inspect the preview and the saved file before sharing. Remove credentials from the source, hide private paths and hostnames, and check the integrated terminal, status bar, open tabs, and notifications. A screenshot tool records what is visible; it does not know which text is confidential.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The history file cannot be found

Open the Capture Window settings and verify its configured history folder. A relative path, a folder without write permission, or a workspace-specific setting can make the saved image appear to be missing. Change the folder to a writable location and run Take Screenshot again.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Compare the workflows before you capture

Method Scope Typical output Best use Main limitation
ScreenshotNeo Web page at a URL PNG, JPEG, WebP, or PDF Automated captures of browser-hosted editors, documentation, and demos Cannot capture a private local desktop window without making it available at a URL
Code Screenshot Selected code PNG, SVG, or GIF Readable snippets for issues, tutorials, and messages Requires an extension and an editor selection
Capture Window VS Code window Saved window image with history Showing panels, tabs, and editor layout Requires an extension and its history settings
Operating-system tool Window, region, or desktop Whatever image format the OS offers One-off captures with no VS Code extension Usually has fewer code-card presentation controls

Or skip the browser setup

If the page you need to document is available at a URL, ScreenshotNeo can perform the browser capture through one request. It accepts a URL and returns a PNG, JPEG, WebP, or PDF. Before the capture it accepts cookie or consent banners and removes more than 60 known consent platforms, newsletter popups, and chat widgets; each cleanup step can be disabled. Bot checks or CAPTCHAs, blank pages, timeouts, failed loads, and cache hits are not billed, and the response identifies the page verdict and billing status with X-Page-Verdict and X-Billed headers.

For a hosted VS Code or documentation page, see the ScreenshotNeo API documentation. Replace the example URL with the page you own or are authorized to capture.

cURL

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://code.visualstudio.com -o shot.webp

Python

import requests
r = requests.get("https://api.screenshotneo.com/v1/shot", params={"access_key": "YOUR_API_KEY", "url": "https://code.visualstudio.com"}, timeout=90)
r.raise_for_status()
open("shot.webp", "wb").write(r.content)

Node.js

const q = new URLSearchParams({ access_key: 'YOUR_API_KEY', url: 'https://code.visualstudio.com' });
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);
if (!res.ok) throw new Error(`Screenshot failed: ${res.status}`);
const body = Buffer.from(await res.arrayBuffer());
require('fs').writeFileSync('shot.webp', body);

Options useful for editor and documentation pages

  • Full-page capture with lazy images loaded, or one element selected by CSS selector.
  • Dark mode, 12 device presets, arbitrary viewport sizes, and retina scale.
  • Custom CSS or JavaScript, clicks before capture, hidden selectors, and waits for a selector, delay, or network idle.
  • Blocking for ads, trackers, requests, or resource types; custom headers, cookies, user agent, Authorization, timezone, and geolocation.
  • Transparent backgrounds, image resizing, a chosen cache TTL, signed links for public <img> tags, asynchronous jobs with signed webhooks, bulk capture of up to 100 URLs per call, a usage API, and an OpenAPI specification.

ScreenshotNeo also provides an MCP server for Claude, Cursor, and other MCP clients, with take_screenshot, get_page_info, and capture_pdf tools. Parameter names used by other screenshot APIs are accepted to ease migration.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Plans and billing

Plan Included shots per month Price
Free 1,000 $0, no card
Starter 3,000 $5
Growth 15,000 $15
Pro 60,000 $39
Scale 250,000 $99
Business 1,000,000 $249

Every feature is included on every plan, and yearly billing gives two months free. You can start with 1,000 free screenshots a month with no card, then move to the $5 Starter plan when you need 3,000 shots.

Capture checklist

  • Decide whether the target is selected code, the VS Code window, the full desktop, or a URL.
  • Remove secrets and private information before selecting or arranging the view.
  • Use the Command Palette when a shortcut is unknown or conflicted.
  • Check the preview, output format, image dimensions, and saved location.
  • Open the final file once before posting it to verify that no notification, terminal line, or unrelated tab was included.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.