Developers

MiniPic VS Code extension

The MiniPic extension for VS Code lets you right-click images in the Explorer to compress them, or convert them to WebP and update the references in your code. The extension itself is free to install; compressing images uses your API quota.

Free extension · Compression uses API quota · 500 free calls a month after sign-up

Install
# Search for MiniPic in the Extensions view, or run this in the Command Palette (⇧⌘P):
ext install minipic.minipic-vscode

Install

Install: search for MiniPic in the VS Code Marketplace.

On the Visual Studio Marketplace, the extension ID is minipic.minipic-vscode.

For Cursor, Windsurf, VSCodium and other editors, install minipic/minipic-vscode from Open VSX.

Visual Studio MarketplaceOpen VSXExtension source code

Right-click to compress

Right-click to compress: one image, a selection or a whole folder.

Select images or a folder in the Explorer and right-click “MiniPic: Compress Images”; folders are processed recursively. Files that would get bigger after compression, or that exceed the size limit, are skipped automatically.

One image

Select an image and right-click to compress it.

Multiple images

Select several at once and compress them together.

Whole folder

Right-click a folder to compress the images inside it, recursively.

Convert to WebP

Convert to WebP and update the references in your code.

Convert images to WebP in one click and rewrite the references to them across your project, with no manual find-and-replace.

Example
  // After “Convert to WebP and Update References”
- <img src="images/hero.png" alt="">
+ <img src="images/hero.webp" alt="">

Auto compression

Auto compression, one click from the status bar.

Turn on auto compression in the status bar, and images added or changed in your workspace are processed automatically. It uses API quota, so it’s off by default.

Key & usage

Set your API key and check your usage.

Quality options are smart, high, extreme and lossless; output formats are keep, png, jpeg, webp, gif, avif and tiff.

Get an API key

Secure storage

Your API key is kept in the editor’s SecretStorage, not in plain-text settings.

Automatic region detection

Detects the China or international edition from your key, so you don’t have to enter an endpoint.

View usage

See how many API calls you’ve used this month, anytime.

FAQ

Does the extension cost anything?

It’s free to install; compressing uses your API quota, and you get 500 calls a month when you sign up.

Do I need an API key?

Yes. Create an API key in the console and enter it in the extension. The extension detects from the key whether to use the China or international edition.

Can it convert images to WebP and update code references?

Yes. “Convert to WebP and Update References” creates the WebP files and replaces references to the original images in your code.

Can it compress a whole folder?

Yes. Right-click a folder in the Explorer to batch-compress the images in it.