User Rating 0.0 โ˜…โ˜…โ˜…โ˜…โ˜…
Total Usage 0 times
Drop image here or click to browse PNG, JPG, SVG, WebP
Upload an image to begin
Is this tool helpful?

Your feedback helps us improve.

โ˜… โ˜… โ˜… โ˜… โ˜…

About

Placing a logo or symbol inside an icon frame requires precise arithmetic. A 1-pixel offset at 16ร—16 is a 6.25% positional error - visible on every browser tab. This tool computes the exact scale factor s = min(W โˆ’ 2pw, H โˆ’ 2ph) to fit your image within the target canvas while preserving aspect ratio, then derives pixel-perfect center offsets. It handles transparent backgrounds, solid colors, linear gradients, configurable border-radius via arcTo clipping, and drop shadows. All rendering happens on an HTML Canvas element in your browser. No image data leaves your machine.

The tool covers standard platform requirements: favicons at 16, 32, 48px, Apple Touch at 180px, Android adaptive at 512px, Open Graph at 1200ร—630px. Mismatched icon sizes cause blurry rendering on high-DPI screens or rejection by app store validators. Pro tip: Apple requires no transparency and no rounded corners in submitted assets - the OS applies its own mask.

icon maker icon generator centered icon favicon generator app icon image centering icon creator

Formulas

The core centering algorithm computes a uniform scale factor that fits the source image into the padded canvas area without distortion:

s = min(W โˆ’ 2pw, H โˆ’ 2ph)

Center offsets position the scaled image exactly in the middle:

ox = W โˆ’ w โ‹… s2
oy = H โˆ’ h โ‹… s2

Where W, H = canvas width and height in pixels. w, h = source image natural width and height. p = padding in pixels (derived from percentage: p = P% โ‹… min(W, H) รท 100). s = uniform scale factor. ox, oy = drawing offset from top-left corner.

Border radius clipping uses a rounded rectangle path. The effective radius is clamped: r = min(R% โ‹… min(W, H) รท 200, min(W, H) รท 2). At R% = 100, the shape becomes a circle (when W = H).

Reference Data

Platform / ContextSize (px)FormatTransparencyNotes
Favicon (classic)16ร—16ICO / PNGYesBrowser tab. ICO supports multi-size.
Favicon (modern)32ร—32PNGYesHigh-DPI tabs and bookmarks.
Favicon (large)48ร—48PNGYesWindows taskbar shortcut.
Apple Touch Icon180ร—180PNGNoiOS home screen. No transparency allowed.
Android Chrome192ร—192PNGYesmanifest.json icon.
Android Adaptive512ร—512PNGYesPlay Store listing, splash screens.
Microsoft Tile (small)70ร—70PNGYesWindows Start menu small tile.
Microsoft Tile (medium)150ร—150PNGYesWindows Start menu medium tile.
Microsoft Tile (large)310ร—310PNGYesWindows Start menu large tile.
Open Graph / Twitter1200ร—630PNG / JPEGNoSocial media share preview.
Slack App Icon512ร—512PNGYesWorkspace app directory.
Discord Bot Avatar256ร—256PNG / JPEGYesMinimum 128px recommended.
macOS App Icon1024ร—1024PNGYesXcode iconset master size.
watchOS Icon1024ร—1024PNGNoCircular mask applied by OS.
PWA Splash (portrait)640ร—1136PNGNoiPhone SE splash screen.
YouTube Channel800ร—800PNG / JPEGNoRendered as circle at 98px.
Instagram Profile320ร—320JPEGNoCircular crop. Minimum 110px.
Twitch Emote (large)112ร—112PNGYesMust also provide 28 and 56px.
Electron / Desktop App256ร—256PNG / ICOYesTray icon. Use 16px for tray.
Custom (square)Any ร— AnyPNG / JPEG / WebPOptionalUser-defined dimensions.

Frequently Asked Questions

High-DPI screens render CSS pixels at 2ร— or 3ร— physical resolution. A favicon declared as 32ร—32 CSS pixels needs a 64ร—64 or 96ร—96 source PNG to appear sharp. Export at the largest target size and let the browser or OS downscale. This tool renders at exact pixel dimensions on the canvas, so a 512ร—512 export contains 512ร—512 actual pixels with no upscaling artifacts.
Padding is computed as a fraction of the shorter canvas dimension: p = P% โ‹… min(W, H) รท 100. For a 512ร—512 canvas with 10% padding, each side gets 51.2px of inset, leaving a 409.6px drawing area.
The algorithm uses the minimum of horizontal and vertical scale factors. This guarantees the entire image fits inside the padded region without cropping. The remaining space on the shorter axis is split equally on both sides, producing centered letterboxing filled by the chosen background.
Border-radius applies a clip path to the entire canvas before any drawing occurs. Both the background fill and the image are clipped. This matches how iOS and Android apply icon masks. At 100% radius on a square canvas, the output is a perfect circle.
PNG preserves transparency and is lossless. Use it for favicons, app icons, and any asset requiring an alpha channel. JPEG discards transparency (fills with white) and uses lossy compression - suitable for social media previews where file size matters. WebP offers both transparency and superior compression ratios but lacks support in older Safari versions before 14.
Yes. Select a batch preset (e.g., 'Favicon Set') which queues sizes 16, 32, 48, 180, 192, and 512. The tool renders each size sequentially on the same canvas configuration and triggers individual downloads. For ICO format bundling, you would need an external tool - this generator outputs standard raster images.