Img Srcset Builder
Builds an <img> tag with a responsive srcset from URLs and widths, ideal for fluid images.
Responsive images without guessing srcset syntax
You exported the same photo at 400, 800 and 1200 pixels and now you need the markup that lets the browser pick the right one. The syntax is short but fussy: a w descriptor after each URL, commas between entries, and a sizes value nobody remembers by heart. One small mistake and the browser quietly ignores the whole srcset and downloads whatever sits in src. This builder glues the four parts into a finished tag.
Worth knowing what the tool does and does not do. It concatenates four fields into an img tag, and srcset is a free-text field: you type the full list yourself in the form url 400w, url 800w. There is no per-file input, no width detection and no validation. The part that trips most people is sizes: leave it out and the browser assumes 100vw, usually fetching a bigger file than needed, because the choice happens before layout exists.
Double-check that the number before each w is the file's real pixel width, not the slot width in your layout, and never mix w and x descriptors in one list. The alt text is genuinely required. If what you actually need is a different crop on phones, srcset is the wrong tool and the picture element with source is the right one. The tag is assembled in your browser, and no URL or image leaves the page.
Frequently asked questions
What is the difference between srcset and picture?
Why does the browser always download the largest file?
Can I use 2x instead of 400w?
Related Tools
HTML Form Builder
Builds a <form> with inputs from a list of name:type entries and configurable action/method.
HTML Rating Stars Builder
Builds a sequence of filled/empty stars representing a numeric rating from 0 to 5.
Iframe Builder
Builds a generic <iframe> with src, width, height and optional sandbox/allow attributes.
HTML Toggle Switch Builder
Builds an iOS-style toggle switch with label using <input type=checkbox> and inline CSS.
Tel Link Builder
Build clickable tel: links from a phone number in the international E.164 format. Great for call buttons on mobile sites, email signatures and contact pages.
Bookmarklet Builder
Wraps a JavaScript snippet as a bookmarklet (javascript: link) ready to drag to the bookmarks bar.