# convertimage: Convert Image Format – PNG, JPEG, GIF, BMP, TIFF

> convertimage (Convert Image Format – PNG, JPEG, GIF, BMP, TIFF) is a 1001fx API function in the group Images: POST https://api.1001fx.com/images/convertimage, 3 credits per call. It works as a ready-made module in Make or as a plain HTTP call.

Converts an image into PNG, JPEG, GIF, BMP or TIFF. Transparent areas become the background color for formats without transparency (JPEG, BMP).

- Group: Images
- Endpoint: `POST https://api.1001fx.com/images/convertimage`
- Authentication: header `X-API-KEY: YOURSECRETAPIKEY`
- Content type: multipart/form-data
- Credits: 3 credits per call
- Ready-made in: Make
- Docs: https://1001fx.com/functions/convertimage

## Parameters

- `file` (file, optional) – File: The image (PNG, JPEG, BMP, TIFF, GIF). Either file or fileUrl.
- `fileUrl` (string, optional) – File URL: Public URL of the image. Either file or fileUrl.
- `format` (enum, required, one of `png`, `jpeg`, `bmp`, `tiff`, `gif`) – Format: Target format.
- `quality` (number, optional, default `90`, min 1, max 100) – JPEG quality: 1 to 100, default 90.
- `background` (string, optional, default `#ffffff`) – Background: Color behind transparent areas for JPEG/BMP, default #ffffff.

## Example: Convert Image Format – PNG, JPEG, GIF, BMP, TIFF

```bash
curl -X POST 'https://api.1001fx.com/images/convertimage' \
  -H 'X-API-KEY: YOURSECRETAPIKEY'
```
