tinypng-mcp-server
This server provides image compression and manipulation using the TinyPNG API. It supports:
Compress local images: Reduce file size of local image files using absolute file paths while maintaining quality
Compress remote images: Compress images from URLs by downloading and processing them
Resize images: Change dimensions using various methods (scale, fit, cover, thumb) with specified width and height parameters
Format conversion: Convert between formats (JPEG, PNG, WebP, AVIF) during compression
Metadata preservation: Optionally preserve copyright, creation date, and location metadata during local image compression
Custom output paths: Save processed images to specified locations with custom filenames, or use auto-generated default paths
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@tinypng-mcp-server compress this local image at /Users/alex/Pictures/logo.png"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP server for TinyPNG
Usage
Use bun or node to run the server
Install dependencies and build
pnpm i
pnpm buildEdit the
mcp.jsonfile
{
"mcpServers": {
"tinypng": {
"command": "bun", // or "node"
"args": ["/path/to/tinypng-mcp-server/src/index.ts"], // or "dist/index.js"
"env": {
"TINYPNG_API_KEY": "your-tinypng-api-key"
}
}
}
}Installing via Smithery
To install TinyPNG MCP Server for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install @aiyogg/tinypng-mcp-server --client claudeTools
Compress local image
{
name: 'compress_local_image',
description: 'Compress a local image file',
inputSchema: {
type: 'object',
properties: {
imagePath: {
type: 'string',
description: 'The ABSOLUTE path to the image file to compress',
example: '/Users/user/Downloads/image.jpg',
},
outputPath: {
type: 'string',
description: 'The ABSOLUTE path to save the compressed image file',
example: '/Users/user/Downloads/image_compressed.jpg',
},
outputFormat: {
type: 'string',
description: 'The format to save the compressed image file',
enum: SUPPORTED_IMAGE_TYPES,
example: 'image/jpeg',
},
},
required: ['imagePath'],
},
}Compress remote image
{
name: 'compress_remote_image',
description: 'Compress a remote image file by giving the URL of the image',
inputSchema: {
type: 'object',
properties: {
imageUrl: {
type: 'string',
description: 'The URL of the image file to compress',
example: 'https://example.com/image.jpg',
},
outputPath: {
type: 'string',
description: 'The ABSOLUTE path to save the compressed image file',
example: '/Users/user/Downloads/image_compressed.jpg',
},
outputFormat: {
type: 'string',
description: 'The format to save the compressed image file',
enum: SUPPORTED_IMAGE_TYPES,
example: 'image/jpeg',
},
},
required: ['imageUrl'],
},
}Available Tools
3 toolscompress_local_imageC
Compress a local image file
Inputs: imagePath (required), outputPath, outputFormat, preserveMetadata.
compress_remote_imageC
Compress a remote image file by giving the URL of the image
Inputs: imageUrl (required), outputPath, outputFormat.
resize_imageC
Resize an image file
Inputs: imagePath (required), width (required), height (required), outputPath, +1 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: compress_local_image handles local files, compress_remote_image handles URLs, and resize_image performs a different operation entirely. There is no overlap or ambiguity between these three functions.
All tools follow a consistent verb_noun pattern with snake_case naming: compress_local_image, compress_remote_image, and resize_image. The naming is predictable and uniform throughout the set.
With 3 tools, this server is well-scoped for its purpose of image processing with TinyPNG. Each tool earns its place by covering distinct aspects: local compression, remote compression, and resizing. This is an appropriate number for the domain.
The tool surface covers the core operations for image compression and resizing with TinyPNG, handling both local and remote sources. A minor gap might be the lack of a tool for batch processing or metadata retrieval, but agents can work around this with sequential calls.
Maintenance
Related MCP Connectors
Compress, resize and convert images with TinyPNG by URL, and check this month's compression count.
Convert images to PNG, JPEG, WebP, or AVIF through one public remote MCP tool.
Image processing over MCP: compress and split images, generate images and QR codes.
Related MCP Servers
- AlicenseCqualityNot gradedmaintenanceImage Tools MCP is a Model Context Protocol (MCP) service that retrieves image dimensions and compresses images from URLs and local files using the TinyPNG API. It supports converting images to formats like webp, jpeg/jpg, and png, providing detailed information on width, height, type, and compressi221 npm9MIT
- AlicenseBqualityDmaintenance🧙🏻 Integrated TinyPNG MCP server, quickly use TinyPNG through LLMs.36 npmApache 2.0
- AlicenseNot gradedqualityBmaintenanceMCP implementation for connecting to the Mochify image processing API to convert, compress and resize images.1MIT
- AlicenseAqualityBmaintenanceMCP server for tinify.ai image optimization. AI-powered upscaling, resizing/cropping, compression, and SEO filename & alt text generation — all in one tool.562 npm2MIT