Image hosting for developers

Image to URL in one API request

Upload a PNG, JPG, SVG, WebP, or other image and get a direct FilePost CDN URL for websites, apps, and automation.

Get free API key 1 provisional / 15 verified uploads/mo · no credit card

How to turn an image into a URL

A direct image URL is useful when an app, email, CMS, or automation step needs a stable reference instead of a local file or an expiring attachment link. FilePost stores the image you send and returns its public CDN URL in the JSON response.

The API accepts common raster and vector formats, including PNG, JPEG, GIF, SVG, WebP, AVIF, and HEIC. Set the filename mode to public when the original filename belongs in the URL; otherwise the default keeps it out of the public path.

Upload image files with FilePost

Use the authenticated FilePost upload API for image files. The endpoint returns a JSON object containing the public URL, file ID, size, content type, and filename mode.

curl -X POST https://upload.filepost.dev/v1/upload \
  -H "X-API-Key: YOUR_API_KEY" \
  -F "file=@photo.jpg"

Example response

{
  "url": "https://cdn.filepost.dev/file/…",
  "file_id": "a1b2c3d4e5f6",
  "name": "photo.jpg",
  "size": 84210,
  "content_type": "image/jpeg"
}

What to do with the returned URL

Use the returned URL directly in an image tag, CSS background, email, CMS record, or downstream workflow.

<img src="https://cdn.filepost.dev/file/…" alt="Uploaded image">

Good uses for image to URL

  • Website and product-image uploads
  • Images from forms and automation workflows
  • Public assets that need a stable HTTPS URL

Know the boundary

FilePost hosts the image bytes; it does not resize, crop, optimize, or generate responsive variants. Use a media-transformation service when those operations are the core requirement.

For the complete request and response contract, see the FilePost API documentation. You can also test the flow with the interactive upload on the homepage.

Image to URL FAQ

What image formats can I upload?

FilePost accepts PNG, JPG, JPEG, GIF, SVG, WebP, AVIF, HEIC, and other image formats. The file is served with the content type you send or the type detected by the upload request.

Can I use the image URL in an img tag?

Yes. The returned HTTPS CDN URL is designed to be used as a normal public asset URL in an img tag, CSS, an email, or an application response.

Does FilePost optimize or resize images?

No. FilePost is the upload-and-host layer. It keeps the bytes you upload and returns a stable URL; use an image transformation service if you need resizing or optimization.

Ready to turn image files into URLs?

Start free, make one API request, and keep the returned CDN URL in your app or workflow.

Get free API key 1 provisional / 15 verified uploads/mo · no credit card