Web Assets Generator Skill
Generates favicons, app icons, Open Graph images, and social media meta assets for web projects. Creates all required sizes from a single source image with proper HTML meta tags for cross-platform compatibility.
Description
This skill generates all the visual assets a web project needs: favicons (ICO, PNG, SVG), Apple touch icons, Android/Chrome icons, Open Graph images, Twitter cards, and the associated HTML meta tags. Provide a single source image and it produces every size and format needed for full cross-browser and social media compatibility.
Instructions
- Input: Accept a source image (SVG preferred, PNG at minimum 1024x1024)
- Generate Sizes: Create all required icon sizes for each platform
- Meta Tags: Output the HTML
<head>tags for proper linking - Manifest: Update or create
manifest.json/site.webmanifest - Social: Generate Open Graph and Twitter Card images with text overlay
Rules
- Source image should be square for icons (non-square images will be center-cropped)
- Always generate both ICO (legacy) and PNG (modern) favicons
- Include SVG favicon when source is SVG (best quality at any size)
- Open Graph images must be exactly 1200x630 pixels
- Twitter Card images must be exactly 1200x600 pixels (summary_large_image)
- Apple touch icons must NOT have transparency (add white/colored background)
- Always generate a
site.webmanifestwith proper icon references - Use progressive JPEG for OG images, PNG for icons
- Optimize all output files for smallest file size
Required Asset Sizes
Favicons
| File | Size | Format | Purpose |
|---|---|---|---|
favicon.ico | 16x16, 32x32, 48x48 | ICO (multi-size) | Legacy browsers |
favicon-16x16.png | 16x16 | PNG | Modern browsers |
favicon-32x32.png | 32x32 | PNG | Modern browsers |
favicon.svg | scalable | SVG | Best quality (if source is SVG) |
Apple Touch Icons
| File | Size | Format | Purpose |
|---|---|---|---|
apple-touch-icon.png | 180x180 | PNG (no transparency) | iOS home screen |
apple-touch-icon-152x152.png | 152x152 | PNG | iPad |
apple-touch-icon-120x120.png | 120x120 | PNG | iPhone |
Android/Chrome
| File | Size | Format | Purpose |
|---|---|---|---|
android-chrome-192x192.png | 192x192 | PNG | Android home screen |
android-chrome-512x512.png | 512x512 | PNG | Android splash screen |
maskable-icon-512x512.png | 512x512 | PNG (safe zone) | PWA maskable icon |
Social Media
| File | Size | Format | Purpose |
|---|---|---|---|
og-image.jpg | 1200x630 | JPEG | Facebook, LinkedIn |
twitter-card.jpg | 1200x600 | JPEG | Twitter/X |
HTML Meta Tags
<!-- Favicons --> <link rel="icon" type="image/x-icon" href="/favicon.ico"> <link rel="icon" type="image/svg+xml" href="/favicon.svg"> <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png"> <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"> <!-- Apple --> <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"> <!-- Manifest --> <link rel="manifest" href="/site.webmanifest"> <meta name="theme-color" content="#ffffff"> <!-- Open Graph --> <meta property="og:image" content="https://example.com/og-image.jpg"> <meta property="og:image:width" content="1200"> <meta property="og:image:height" content="630"> <meta property="og:image:type" content="image/jpeg"> <!-- Twitter --> <meta name="twitter:card" content="summary_large_image"> <meta name="twitter:image" content="https://example.com/twitter-card.jpg">
Generation Script (sharp/Node.js)
const sharp = require('sharp'); const path = require('path'); const SIZES = { 'favicon-16x16.png': 16, 'favicon-32x32.png': 32, 'apple-touch-icon.png': 180, 'android-chrome-192x192.png': 192, 'android-chrome-512x512.png': 512, }; async function generateIcons(sourcePath, outputDir) { for (const [filename, size] of Object.entries(SIZES)) { await sharp(sourcePath) .resize(size, size, { fit: 'cover', background: '#ffffff' }) .flatten({ background: '#ffffff' }) // Remove transparency for Apple .png({ quality: 90 }) .toFile(path.join(outputDir, filename)); console.log(`Generated: ${filename}`); } }
Examples
"Generate all favicon sizes from my logo.svg"
"Create Open Graph images for my site with the title 'My App'"
"Update the HTML meta tags for proper social media previews"
"Generate a PWA manifest with icons from this source image"
Reviews
No reviews yet. Be the first to review this template!
Similar Templates
Full-Stack Code Reviewer
Comprehensive code review skill that checks for security vulnerabilities, performance issues, accessibility, and best practices across frontend and backend code.
Test Suite Generator
Generates comprehensive test suites with unit tests, integration tests, and edge cases. Supports Jest, Vitest, Pytest, and Go testing.
Pro Architecture Workspace
Battle-tested skill for architectural, decision, making, framework. Includes structured workflows, validation checks, and reusable patterns for development.