# Convert PGM to BMP

Files are processed on our server, and the results are kept for a few minutes so you can download them, then deleted — whether or not you did. Free, no account, no watermark.

Results are deleted 15 minutes after the job finishes.

## API

POST the file as the raw request body to https://toolsforfree.app/api/jobs?from=pgm&to=bmp, then

GET https://toolsforfree.app/api/jobs/{taskId}?engine={engine} until state is done,
then GET https://toolsforfree.app/api/jobs/{taskId}/output?engine={engine}&format={format}, with the taskId, engine and format the 202 answers.

Details: https://toolsforfree.app/api.md

MCP: call convert_file at https://toolsforfree.app/mcp with from "pgm" and to "bmp".

## Options

Sent as JSON in the x-tff-options header. Bounds and allowed values are in https://toolsforfree.app/openapi.json.

- `image`: quality, targetKb, lossless, effort, width, height, fit, focus, allowEnlarge, stripMetadata, rotate, autoOrient, density, page, flip, background, crop

## Questions

### Does converting PGM to BMP lose quality?

No. Both store the data exactly, so the result is the same content in a different container.

### Can I convert the BMP back to PGM?

Not here. We can read BMP but no engine of ours writes PGM, so this conversion only goes one way.

### What can I change about the BMP it produces?

You can choose the width and height, whether to keep the shape, a size by percent, whether to enlarge, and the colour behind transparent areas.
