Flip an image
Sometimes an image just needs to face the other way: a product photo shot from the wrong side, a scanned negative that reads backwards, a design element that needs to mirror its pair. This endpoint flips the image horizontally or vertically and returns the mirrored version, without touching anything else about it.
Run it online
Run this on our servers with your account. Free tools run in your browser; this one bills your KIT balance per the price above.
Flip versus rotate, and why the distinction matters
It's easy to conflate flipping with rotating, but they solve different problems. Rotating turns an image around a point, useful for fixing sideways orientation; flipping mirrors it across an axis, which is what you need when the content itself is reversed, like text read through the back of a scanned page, a logo that needs a mirrored counterpart for a symmetrical layout, or a photo where the subject is facing the wrong direction for the design it sits in.
How the call works
You send the image to /image/flip and specify horizontal or vertical, and it returns the mirrored file. The request returns a task_id immediately, the flip itself runs asynchronously, and you get the result through a signed webhook or a signed link that stays valid for 24 hours — the same delivery pattern across every task in the system, so you don't have to special-case this one endpoint in your integration.
Where flipping actually gets used
It shows up more often than people expect: product photography where a left-facing shoe needs a right-facing counterpart for a paired listing, print layouts where an image needs to mirror for a foldout or reverse-side print, scanned film negatives that came out backwards, and design systems generating symmetrical icon sets from a single source asset. In each case the alternative is re-shooting or re-drawing the asset, when a mirror flip does the job in one call.
Fitting it into a larger pipeline
Because it's a single, predictable POST, it composes cleanly with other tasks in a pipeline — flip, then rotate, then convert format, each as its own async step with its own task_id. A failed flip retries automatically up to three times before returning a clear error, and you're never charged for a task that doesn't complete, which matters when a pipeline is running unattended against a batch of unpredictable source files.
Who this serves
Design teams building mirrored asset pairs, e-commerce catalogs standardizing product orientation, and archival projects correcting scanned negatives all use flipping as a small, precise fix rather than reaching for a full image editor.
What you can do with it
Mirrored product pairs
A footwear retailer generates a mirrored right-shoe image from a single left-shoe photo instead of shooting both angles separately.
Scanned negative correction
An archival digitization project flips scanned film negatives that came out reversed, restoring the correct left-right orientation.
Symmetrical icon generation
A design system creates a mirrored counterpart of a directional icon, like an arrow or a chevron, from a single source SVG rendered as PNG.
Print foldout layout
A print shop flips an image vertically to match the reversed orientation needed for one panel of a folded brochure.
FAQ
What's the difference between flipping and rotating an image?
Flipping mirrors an image across a horizontal or vertical axis, reversing its content, while rotating turns the whole image around a point without mirroring it.
Can I flip both horizontally and vertically?
Yes, you specify the direction in the request; to flip on both axes, send two requests or one after the other in your pipeline.
Is flipping images free?
There's no free tier — free tiers get abused and slow everyone down. Access runs on a prepaid ForHosting KIT balance: top up from $10.00 (it never expires) and each request is charged at its published price, so a call with no balance returns HTTP 402. No subscription, no tokens, no invented credits, and a failed task is never charged.
How much does it cost to flip an image?
$0.002 per request plus $0.005 per image, and failed tasks are never billed.
Is the flip applied instantly?
No, it's processed asynchronously. You get a task_id right away, and the flipped image arrives via signed webhook or a signed link valid for 24 hours.
Does flipping affect image quality?
No, a horizontal or vertical flip simply rearranges pixels without resampling, so there's no quality loss.
What image formats does the flip API support?
It works with standard raster formats including JPG, PNG, BMP, TIFF and WebP.
What happens if I submit a corrupted file?
The task retries automatically up to three times, and if it still can't be processed you get a clear error with no charge.
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, and soon from our app, email and Telegram.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/image/flip \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"image":"https://ejemplo.com/imagen.jpg"}'const res = await fetch("https://api.kit.forhosting.com/image/flip", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"image": "https://ejemplo.com/imagen.jpg"
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/image/flip",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"image": "https://ejemplo.com/imagen.jpg"
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/image/flip", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"image":"https://ejemplo.com/imagen.jpg"}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"image":"https://ejemplo.com/imagen.jpg"}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/image/flip", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"image": "https://ejemplo.com/imagen.jpg"
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "image.flip",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Limits
max_mb | 15 |
max_megapixels | 12 |
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |