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

Use two Chrome extension APIs in sequence: call chrome.tabs.captureVisibleTab() to get an image representation of the active tab’s visible area, then pass that result to chrome.downloads.download() to save it. Declare the permissions for both operations, trigger activeTab from a user action when possible, and keep automated captures below Chrome’s documented maximum of two calls per second.

What this workflow actually captures

chrome.tabs.captureVisibleTab captures the currently active tab’s visible area in a browser window. It is not a full-page screenshot API: content below the viewport is not included merely because the page can scroll. The method returns a Promise that resolves to a string containing the image representation.

chrome.downloads.download performs a separate job. It accepts a URL and creates a download, optionally applying a filename and asking Chrome to show a Save As dialog. Keeping capture and download as separate steps makes it easier to retry a failed save without taking another screenshot.

Permissions you need

Task Permission or condition Scope and guidance
Capture the active tab after a user action activeTab Grants temporary access to the current tab in response to a user invocation. It is generally the narrower choice for an action-triggered workflow and does not produce the usual host-permission warning described for broad access.
Capture tabs without relying on a user invocation <all_urls> The capture reference lists this as the alternative host permission. Request it only when your product genuinely needs automatic access across sites, and explain that scope to users.
Save the image as a download downloads Required by chrome.downloads.download.
Capture a file:// page User-granted file access The user must enable the extension’s access to file URLs in Chrome’s extension settings in addition to your declared permissions.

Minimal Manifest V3 setup

This manifest supports a toolbar-button workflow. Clicking the extension action is the user invocation that lets activeTab apply to the current tab.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Amazon Basics Wired QWERTY Keyboard, Works with Windows, Plug and Play, Easy to Use with Media Control, Full-Sized, Black
  • KEYBOARD: The keyboard works for Windows with hot keys that enable easy access to Media, My Computer, Mute, Volume up/down, and Calculator
  • EASY SETUP: Experience simple installation with the USB wired connection
  • VERSATILE COMPATIBILITY: This keyboard is designed to work with multiple Windows versions, including Vista, 7, 8, 10 offering broad compatibility across devices.
  • SLEEK DESIGN: The elegant black color of the wired keyboard complements your tech and decor, adding a stylish and cohesive look to any setup without sacrificing function.
  • FULL-SIZED CONVENIENCE: The standard QWERTY layout of this keyboard set offers a familiar typing experience, ideal for both professional tasks and personal use.
{
  "manifest_version": 3,
  "name": "Visible Tab Saver",
  "version": "1.0.0",
  "permissions": ["activeTab", "downloads"],
  "action": {
    "default_title": "Save visible tab screenshot"
  },
  "background": {
    "service_worker": "service-worker.js"
  }
}

If your extension must capture tabs independently of a user action, replace activeTab with the host access your design requires, such as <all_urls>. Do not combine broad host access with an action-only feature unless there is a specific reason.

Capture, then download

Toolbar-button example

The following service worker shows the intended sequence and names each file under a screenshots directory inside the user’s Downloads folder.

chrome.action.onClicked.addListener(async (tab) => {
  if (!tab.id || tab.windowId === undefined) {
    console.error("No capturable tab was supplied");
    return;
  }

  try {
    const imageUrl = await chrome.tabs.captureVisibleTab(tab.windowId, {
      format: "png"
    });

    const downloadId = await chrome.downloads.download({
      url: imageUrl,
      filename: `screenshots/tab-${Date.now()}.png`,
      saveAs: false
    });

    console.log("Download started:", downloadId);
  } catch (error) {
    console.error("Screenshot or download failed:", error);
  }
});

Important compatibility qualification: Chrome’s reference pages document the capture method and the download method separately, but do not provide an authoritative end-to-end example proving that a particular capture-result string can be passed unchanged as the download URL in every manifest version and extension context. The code above expresses the normal bridge, but verify the exact URL handling in the Chrome version and context you support before making it a production guarantee. If your target requires a conversion step (for example, creating a blob or object URL), validate that step with your own target manifest and service-worker/page context rather than assuming a snippet is universal.

Rank #2
Sale
Logitech MK270 Full Size Wireless Keyboard and Mouse Combo - Black
  • Reliable Plug and Play: The USB receiver provides a reliable wireless connection up to 33 ft (1), so you can forget about drop-outs and delays and you can take it wherever you use your computer
  • Type in Comfort: The design of this keyboard creates a comfortable typing experience thanks to the low-profile, quiet keys and standard layout with full-size F-keys, number pad, and arrow keys
  • Durable and Resilient: This full-size wireless keyboard features a spill-resistant design (2), durable keys and sturdy tilt legs with adjustable height
  • Long Battery Life: MK270 combo features a 36-month keyboard and 12-month mouse battery life (3), along with on/off switches allowing you to go months without the hassle of changing batteries
  • Easy to Use: This wireless keyboard and mouse combo features 8 multimedia hotkeys for instant access to the Internet, email, play/pause, and volume so you can easily check out your favorite sites

Choosing the window

Passing tab.windowId captures the window that owns the tab you just received. Omitting the argument makes Chrome use the current window. Supplying the ID is safer when your extension tracks several windows or receives tab data asynchronously.

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.

JPEG, PNG and other capture options

The second argument is an options object. Select the image representation your downstream workflow needs and test the resulting string-to-download bridge for that choice. If you use JPEG, ensure your filename extension matches the representation you request. Do not infer that changing the extension converts the image; the capture result and the filename must agree.

Making captures automatic without hitting the limit

Chrome documents MAX_CAPTURE_VISIBLE_TAB_CALLS_PER_SECOND as 2 and describes the operation as expensive. A timer that fires every few milliseconds will therefore produce rejected calls, wasted work or an unreliable user experience. Treat the limit as a scheduling constraint, not as a target throughput.

Rank #3
Sale
Logitech K120 Full Size Wired Keyboard USB Plug-and-Play Windows - Black
  • All-day Comfort: The design of this standard keyboard creates a comfortable typing experience thanks to the deep-profile keys and full-size standard layout with F-keys and number pad
  • Easy to Set-up and Use: Set-up couldn't be easier, you simply plug in this corded keyboard via USB on your desktop or laptop and start using right away without any software installation
  • Compatibility: This full-size keyboard is compatible with Windows 7, 8, 10 or later, plus it's a reliable and durable partner for your desk at home, or at work
  • Spill-proof: This durable keyboard features a spill-resistant design (1), anti-fade keys and sturdy tilt legs with adjustable height, meaning this keyboard is built to last
  • Plastic parts in K120 include 51% certified post-consumer recycled plastic*

Use a paced queue

For repeated captures, serialize requests and leave at least 500 milliseconds between starts. A queue also prevents several downloads from racing when a capture or disk operation is slow.

const queue = [];
let running = false;

export function enqueueCapture(windowId, filename) {
  queue.push({ windowId, filename });
  void drain();
}

async function drain() {
  if (running || queue.length === 0) return;
  running = true;

  try {
    while (queue.length) {
      const job = queue.shift();
      try {
        const imageUrl = await chrome.tabs.captureVisibleTab(job.windowId, {
          format: "png"
        });
        await chrome.downloads.download({
          url: imageUrl,
          filename: job.filename,
          saveAs: false
        });
      } catch (error) {
        console.error("Queued capture failed:", error);
      }
      await new Promise((resolve) => setTimeout(resolve, 500));
    }
  } finally {
    running = false;
  }
}

This pacing is deliberately conservative. If you need a different schedule, measure the behavior on the Chrome versions you support and retain backoff when Chrome reports a rate-limit or transient failure. Tell users how often captures occur; silent, frequent screenshots can consume system resources and fill the Downloads folder quickly.

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

Keep the queue bounded

  • Discard or coalesce stale jobs when a newer screenshot supersedes them.
  • Stop scheduling when the tab closes, navigates away from the workflow, or no longer matches the user’s selection.
  • Use deterministic names that include a timestamp or sequence number so one capture does not overwrite another unintentionally.
  • Log the download ID and the associated tab/window ID so support can identify which stage failed.

Download behavior and filenames

The download options object requires a URL. The optional filename is a suggested path relative to the Downloads directory; it is not an arbitrary absolute filesystem path. Set saveAs: true when the user should choose a destination for each capture. If you provide both filename and saveAs: true, Chrome documents that the Save As dialog is pre-populated with that filename.

Rank #4
Redragon K521 Upgrade Rainbow LED Gaming Keyboard, 104 Keys Wired Mechanical Feeling Keyboard with Multimedia Keys, One-Touch Backlit, Anti-Ghosting, Compatible with PC, Mac, PS4/5, Xbox
  • 【Dreamy Rainbow Gaming Keyboard】K521 Gaming Keyboard Adopts a Different LED Backlight Design, Upgraded on the Traditional LED Backlight Effect, Making the Light More Penetrating, Giving You a More Dazzling Visual Effect, Making Your Gaming Process More Enjoyable
  • 【One Touch Opens & Visual Feast】The K521 Red Dragon Keyboard has a One-Touch on/off Lighting Button for Added Convenience. It also has a Three-Position Adjustable Breathing Mode and a Four-Position Adjustable Brightness Lighting Mode
  • 【Mechanical Feeling & Fast Tapping】The PC Keyboard Keys are Designed for Mechanical Feeling, Giving You a Better Feel During Use and the Ability to Trigger Keys Quickly, Allowing You to Win All Your Games
  • 【19 Keys Anti-Ghosting Keyboard】Anti-Ghosting Ensures Every Button Can Be Triggered. This Allows You to Trigger Key Combinations In The Game Accurately, And Each Skill Can Be Accurately Released to Increase Your Winning Rate. Redragon K521 Will Be Your Perfect Partner
  • 【12 Multimedia Combination Keys】The K521 Wired Gaming Keyboard is Equipped with 12 Multimedia Keys That Can Greatly Enhance Your Gaming/Office Efficiency and Make It More Convenient to Use

A successful chrome.downloads.download() call resolves to a new download ID. Store that ID if you need to correlate later download events or display status in your extension UI. A successful call means the download was created, not that a user has opened the file.

Visible-area limitations to design around

It is not full-page capture

Only what is visible in the active tab is represented. A long article, dashboard or document will require a separate full-page strategy, such as an application-specific rendering flow or a tool that supports full-page capture. Do not label files from this API as “full page” unless your extension has independently assembled and verified a complete page image.

The active-tab requirement matters

With activeTab, access is temporary and tied to the user invocation. If a user clicks your action and then your code waits while the tab changes, the capture may no longer represent the page the user expected. Capture promptly, and handle a missing tab ID or a changed window as a normal error path.

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.
Best Value
Sale
Logitech K270 Full Size Wireless Keyboard for Windows - Black
  • All-day Comfort: This USB keyboard creates a comfortable and familiar typing experience thanks to the deep-profile keys and standard full-size layout with all F-keys, number pad and arrow keys
  • Built to Last: The spill-proof (2) design and durable print characters keep you on track for years to come despite any on-the-job mishaps; it’s a reliable partner for your desk at home, or at work
  • Long-lasting Battery Life: A 24-month battery life (4) means you can go for 2 years without the hassle of changing batteries of your wireless full-size keyboard
  • Simply plug the USB receiver into a USB port on your desktop, laptop or netbook computer and start using the keyboard right away without any software installation
  • Simply Wireless: Forget about drop-outs and delays thanks to a strong, reliable wireless connection with up to 33 ft range (5); K270 is compatible with Windows 7, 8, 10 or later

File URLs need an extra user setting

An extension can declare the right API permissions and still fail on a local file because Chrome separately requires the user to grant file access. Explain this setting in onboarding or an error message rather than treating it as a mysterious capture failure.

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

Troubleshooting

Symptom Likely cause Fix
The call rejects immediately after installation The manifest lacks activeTab or suitable host access, or the action was not invoked by the user. Declare the narrow permission that matches your workflow, reload the extension, and invoke the action on the tab you intend to capture.
A file:// page cannot be captured The user has not enabled file access for the extension. Open the extension’s details in Chrome and enable access to file URLs, then retry.
Capture works but saving fails downloads is missing, or the capture-result string is not accepted as a download URL in the target context. Add the downloads permission. Then verify the result-to-URL handling for your manifest version and context; do not assume an untested conversion snippet is portable.
Some requests fail during monitoring The extension exceeds the documented two-calls-per-second maximum or starts overlapping captures. Serialize work, wait at least 500 milliseconds between starts, add backoff, and bound the queue.
The image is not the page the user expected The active tab or window changed before capture. Capture immediately after the action, pass the known windowId, and check tab state before queuing delayed work.
Files have the wrong format The filename extension does not match the requested representation. Keep the capture option and filename extension consistent; an extension change alone does not convert image data.

When to use an API service instead

If you need server-side full-page images, repeatable rendering, bulk URLs or AI-agent control, a browser extension may be more machinery than you need. ScreenshotNeo is the first service to try for website screenshots because it removes consent banners, newsletter popups and chat widgets before capture, bills only clean shots, and has the lowest paid plan.

Or skip the browser setup

ScreenshotNeo accepts one GET request and returns a PNG, JPEG, WebP or PDF. The API base is https://api.screenshotneo.com/v1/shot. See the ScreenshotNeo API documentation for the complete parameter list.

cURL

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

Python

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

Node.js

const q = new URLSearchParams({ access_key: 'YOUR_API_KEY', url: 'https://stripe.com' });
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);

It supports full-page capture with lazy images loaded, CSS-selector element shots, dark mode, 12 device presets plus custom viewports, retina scale, PDF paper and page-range controls, custom CSS and JavaScript, clicks before capture, selector hiding, waits for selectors/delays/network idle, blocking ads or resource types, custom headers/cookies/user agents and Authorization, timezone and geolocation, transparent backgrounds, resizing, configurable-TTL caching, signed image links, asynchronous jobs with signed webhooks, bulk capture for up to 100 URLs per call, a usage API and an OpenAPI specification. Parameter names used by other screenshot APIs also work, which can simplify migration.

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

Before capture it accepts cookie or consent banners like a visitor and removes more than 60 known consent platforms, newsletter popups and chat widgets; each cleanup step can be turned off. Bot checks or CAPTCHAs, blank pages, timeouts, failed loads and cache hits cost nothing, and each response identifies the page verdict and billing status with X-Page-Verdict and X-Billed headers. Its MCP server exposes take_screenshot, get_page_info and capture_pdf for Claude, Cursor and other MCP clients.

Plan Included screenshots Price
Free 1,000 per month $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 available on every plan, and yearly billing provides two months free. Create a free ScreenshotNeo account to get 1,000 screenshots each month with no card; paid plans start at $5 for 3,000 screenshots.

Frequently Asked Questions

Can I ask Chrome to save each capture in a different folder?

The API accepts a relative filename under the Downloads directory. It does not provide an arbitrary absolute path; use saveAs: true when the user must choose the destination.

What should I record when diagnosing an intermittent failure?

Record the tab and window IDs, the capture timestamp, the rejected method, and the download ID when one was created. This separates permission, rate-limit, capture and download failures without taking another screenshot.

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

Quick Recap

Bestseller No. 1
SaleBestseller No. 3
Logitech K120 Full Size Wired Keyboard USB Plug-and-Play Windows - Black
Logitech K120 Full Size Wired Keyboard USB Plug-and-Play Windows - Black
Plastic parts in K120 include 51% certified post-consumer recycled plastic*; Product carbon footprint: 4.02 kg CO2e
$12.34
SaleBestseller No. 5
Logitech K270 Full Size Wireless Keyboard for Windows - Black
Logitech K270 Full Size Wireless Keyboard for Windows - Black
Plastic parts in K270 include 38% certified post-consumer recycled plastic; Eight hot keys: For instant access to the Internet, e-mail, music volume and more
$21.48

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.