background-remove.online

For developers

This page describes how our background removal service works from a technical perspective. We offer a free web tool — use it in your browser with no API key or signup. If you're building an app or script, the examples below show the request and response format; for most users, the web tool is the simplest option.

Developer and code
Photo from Pexels

Request

POST https://api.background-remove.online/v1/remove
Content-Type: multipart/form-data
Authorization: Bearer YOUR_API_KEY

Body (form-data):
  image_file: (binary)  — your image (JPG, PNG, or WebP, max 12 MB)
  size: (optional)     — "auto" | "preview" | "full" (default: auto)

Response

Success: 200 OK
Content-Type: image/png
Body: PNG image with transparent background

Error: 4xx/5xx
Content-Type: application/json
{"error": "error_code", "message": "Human-readable message"}

Code examples

cURL example

curl -X POST \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -F "image_file=@/path/to/photo.jpg" \
  https://api.background-remove.online/v1/remove \
  --output result.png

Python example

import requests

url = "https://api.background-remove.online/v1/remove"
headers = {"Authorization": "Bearer YOUR_API_KEY"}
files = {"image_file": open("photo.jpg", "rb")}
r = requests.post(url, headers=headers, files=files)
with open("result.png", "wb") as f:
    f.write(r.content)
Coding
Photo from Pexels

Best practices

For most use cases, the free web tool is enough: no keys, no server setup, and the same quality. Use the API when you need to automate large batches or integrate into an existing backend. See Tools & API for an overview.

When to use the web tool instead

If you only need to remove backgrounds occasionally or from a small number of images, the free web tool is the fastest path: open the page, upload a file, download the PNG. No API key, no code, no deployment. Many developers use it for quick tests before integrating the API into their product.

Use free tool Tools & API overview