swiftimg

Image hosting for static sites: Hugo, Jekyll, Eleventy & Astro

Static-site generators bundle every image into the build, which bloats the repo and slows deploys. Hosting on swiftimg keeps the repo clean and gives you free WebP variants and on-the-fly resizing.

Try swiftimg freeSee the API

Heads-up

If you need fully offline builds (e.g. a totally air-gapped doc site), in-repo images are still the right call. Otherwise, externalising image storage usually pays off.

Step by step

  1. 1. Upload from the CLI

    The @swiftimg/cli package lets you upload from a shell — drop it into a build script or a hotkey.

    Shell
    swiftimg upload hero.png --title "Homepage hero"
  2. 2. Reference it from your template

    Use the direct image URL anywhere you'd reference a local image. Hugo / Jekyll / 11ty / Astro all accept absolute URLs without configuration.

    Template
    <img src="https://i.swiftimg.com/abc123.png" alt="Homepage hero" />
  3. 3. Serve a responsive set

    On the Developer plan, generate width variants with on-the-fly resize and pass them as a srcset.

    Responsive srcset
    srcset="https://i.swiftimg.com/abc123.png?w=480&sig=... 480w,
            https://i.swiftimg.com/abc123.png?w=960&sig=... 960w,
            https://i.swiftimg.com/abc123.png?w=1920&sig=... 1920w"

Static sites (Hugo, Jekyll, Eleventy) — FAQ

Will offline / preview builds still work?

Yes — they fetch images at HTTP request time, not build time. CI builds need network access (almost always available).

How does this compare to using raw object storage directly?

Object storage stores the file; swiftimg adds on-the-fly transforms, signed URLs, an upload UI/API, and a hosted viewer page. If all you need is raw storage, a bucket alone is fine.

Is there a Hugo / Jekyll plugin?

Not yet — the API and CLI are explicitly framework-agnostic. A short build hook usually replaces a plugin in a few lines of shell.

See also

Ready to host your Static sites (Hugo, Jekyll, Eleventy) images?

Start free, then unlock the full API, transforms, signed URLs, and a custom domain on the Developer plan.