🗜️

Code Minifier API

Minify HTML, CSS, and JavaScript to reduce file sizes and improve web performance. Supports all major web languages.

API Endpoint

POST /v1/minify

Parameters

Name Type Required Description
codestringYesSource code to minify
languagestringYesLanguage: html, css, or javascript

Quick Example

curl -X POST "https://api.toolcenter.dev/v1/minify" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"code": "body {  margin: 0;  padding: 0;  }", "language": "css"}'

Features

  • HTML, CSS, and JavaScript minification
  • Whitespace and comment removal
  • Safe minification preserving functionality
  • Size reduction statistics
  • Batch minification support

Use Cases

Optimize assets in CI/CD pipelines

Build online code minification tools

Reduce bundle sizes for web apps

Automate performance optimization workflows

Start Using Code Minifier API for Free

500 free API calls per month. No credit card required.

Get Started Free