Skip to content

Favicon Generator

Generate a complete set of favicon and app icon files from a source image. Produces all standard sizes needed for browsers, Apple devices, and Android, along with a web manifest and an HTML snippet.

API Endpoint

POST /api/v1/tools/favicon

Accepts multipart form data with one or more image files and an optional JSON settings field.

Parameters

ParameterTypeRequiredDefaultDescription
backgroundstringNo-Background hex color (e.g. "#ffffff"). When set, the icon is flattened onto this color.
paddingintegerNo0Padding percentage around the icon content (0 to 40)
radiusintegerNo0Corner radius percentage for rounded icons (0 to 50)
sizesinteger[]No-Restrict output to specific pixel sizes (e.g. [16, 32, 180]). Omit to generate all standard sizes.
themeColorstringNo"#ffffff"Theme color hex for the web manifest

Generated Files

For each input image, the following files are produced:

FileSizePurpose
favicon-16x16.png16x16Browser tab icon
favicon-32x32.png32x32Browser tab icon (HiDPI)
favicon-48x48.png48x48Desktop shortcut
apple-touch-icon.png180x180iOS home screen
android-chrome-192x192.png192x192Android home screen
android-chrome-512x512.png512x512Android splash screen
favicon.ico32x32Legacy ICO format
manifest.json-Web app manifest with icon references
favicon-snippet.html-Ready-to-use HTML link tags

Example Request

Single source image with rounded corners and padding:

bash
curl -X POST http://localhost:1349/api/v1/tools/favicon \
  -H "Authorization: Bearer si_your-api-key" \
  -F "[email protected]" \
  -F 'settings={"padding": 10, "radius": 20, "themeColor": "#0a0a0a"}'

Multiple source images (each gets its own set in a subfolder):

bash
curl -X POST http://localhost:1349/api/v1/tools/favicon \
  -H "Authorization: Bearer si_your-api-key" \
  -F "[email protected]" \
  -F "[email protected]"

Example Response

The response is a ZIP file streamed directly. The response headers are:

Content-Type: application/zip
Content-Disposition: attachment; filename="favicons-a1b2c3d4.zip"

HTML Snippet Included

The ZIP includes a favicon-snippet.html file you can paste into your HTML <head>:

html
<!-- Favicons -->
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="48x48" href="/favicon-48x48.png">
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
<link rel="manifest" href="/manifest.json">

Notes

  • Source images are resized using cover fit mode, meaning they are cropped to fill each square size. For best results, use a square source image.
  • When multiple files are uploaded, each gets its own subfolder in the ZIP (named after the source file).
  • For a single file upload, all outputs are at the root of the ZIP with no subfolder.
  • Files that fail validation or decoding are skipped, and a skipped-files.txt is included in the ZIP explaining the issues.
  • Supported input formats: JPEG, PNG, WebP, AVIF, TIFF, GIF, HEIC, SVG, RAW, PSD, and more.
  • EXIF orientation is auto-applied before resizing.