惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Google DeepMind News
Google DeepMind News
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
酷 壳 – CoolShell
酷 壳 – CoolShell
WordPress大学
WordPress大学
小众软件
小众软件
博客园 - 司徒正美
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Jina AI
Jina AI
Hugging Face - Blog
Hugging Face - Blog
博客园 - Franky
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
量子位
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
雷峰网
雷峰网
云风的 BLOG
云风的 BLOG
M
MIT News - Artificial intelligence
F
Fortinet All Blogs
T
Tailwind CSS Blog
Martin Fowler
Martin Fowler
I
InfoQ
The GitHub Blog
The GitHub Blog
有赞技术团队
有赞技术团队
The Cloudflare Blog
罗磊的独立博客

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
I Built a Free Image Optimizer That Outputs Responsive HT...
Saima Syed · 2026-06-20 · via DEV Community
Cover image for I Built a Free Image Optimizer That Outputs Responsive HTML — No Sign-Up, No Storage

Saima Syed

Every Lighthouse audit I ran on client sites flagged the same three things:

❌ Serve images in next-gen formats
❌ Properly size images
❌ Avoid layout shifts

The existing free tools either compressed one file and called it done, or they stored your uploads on their servers indefinitely. Neither was good enough for client work.
So I built ImgForge — a free, server-side image optimizer that resolves all three Lighthouse image audits in a single upload.

What's wrong with existing tools

Most image optimizers hand you back a smaller JPEG. That's not modern web performance — that's step one of five.
What you actually need is:

AVIF + WebP + JPEG variants — browser support for AVIF still isn't universal
Device-specific sizes — a 1920px image served to a 480px phone wastes ~70–90% of its bytes
A ready-to-paste element — with srcset, sizes, loading, decoding, and fetchpriority already written
EXIF stripped — GPS coordinates, device info, and timestamps have no place in a production image

I couldn't find a single free tool that handled all of this in one pass.

What ImgForge does

Built on Sharp (libvips under the hood — faster than ImageMagick, lower memory footprint, non-blocking async processing), everything runs server-side and streams to your browser as a ZIP. Nothing is stored after download.
One upload produces:

Multi-format output

AVIF, WebP, and JPEG — simultaneously. AVIF typically runs ~50% smaller than JPEG at equal visual quality. JPEG is the universal fallback.
Multi-device variants

Mobile — 480px + @2x Retina
Tablet — 1024px
Desktop — 1920px

Up to 12 variants per image, covering every major breakpoint.

Lighthouse-optimised HTML snippet

<picture>
  <source type="image/avif"
          srcset="images/mobile/imageo-optimizer-online-imageforge_mobile_400.avif 400w,
                  images/mobile/imageo-optimizer-online-imageforge_mobile_800@2x.avif 800w,
                  images/tablet/imageo-optimizer-online-imageforge_tablet_700.avif 700w,
                  images/desktop/imageo-optimizer-online-imageforge_desktop_1200.avif 1200w"
          sizes="(max-width: 480px) 400px, (max-width: 1024px) 700px, 1200px">
  <source type="image/webp"
          srcset="images/mobile/imageo-optimizer-online-imageforge_mobile_400.webp 400w,
                  images/mobile/imageo-optimizer-online-imageforge_mobile_800@2x.webp 800w,
                  images/tablet/imageo-optimizer-online-imageforge_tablet_700.webp 700w,
                  images/desktop/imageo-optimizer-online-imageforge_desktop_1200.webp 1200w"
          sizes="(max-width: 480px) 400px, (max-width: 1024px) 700px, 1200px">
  <img src="images/fallback/imageo-optimizer-online-imageforge.jpg"
       srcset="images/mobile/imageo-optimizer-online-imageforge_mobile_400.png 400w,
               images/mobile/imageo-optimizer-online-imageforge_mobile_800@2x.png 800w,
               images/tablet/imageo-optimizer-online-imageforge_tablet_700.png 700w,
               images/desktop/imageo-optimizer-online-imageforge_desktop_1200.png 1200w"
       sizes="(max-width: 480px) 400px, (max-width: 1024px) 700px, 1200px"
       alt="Free Image Optimizer Online — Compress, Convert & Get Responsive HTML in One Click"
       width="1200" height="800"
       loading="lazy" decoding="async">
</picture>

Paste directly into your project. No manual attribute writing.

Above / below fold control

Hero image? Toggle "Above the Fold" and ImgForge adds fetchpriority="high" plus a tag — protecting your LCP score. Everything else gets loading="lazy" automatically.
Organised ZIP structure
/mobile
/tablet
/desktop
/fallback
snippet.html
README.md

Privacy consideration for client work

This one matters more than people realise: if you upload a client's product photos or brand assets to a third-party tool that stores them, that's a data handling problem. ImgForge processes and streams. Once the ZIP is downloaded, nothing is retained.
No account. No subscription. No storage.

Try it

👉 imageoptimizer.online — free, no sign-up required.
The Format Guide on the site covers AVIF vs WebP vs JPEG compression tradeoffs in detail if you want to go deeper. Feedback welcome — especially if you're using Sharp for anything interesting in your own stack.