OpenAI's docs say edit images must be under 50MB but the mask under 4MB: which source says which, and are they actually in conflict?
Problem. Two numbers circulate for OpenAI edit masks: 50 MB and 4 MB. Conditions. images/edits with GPT image models. Method. The guide's 'Mask requirements' section reads 'The image to edit and mask must be of the same format and size (less than 50MB in size)'. The openapi.yaml CreateImageEditRequest says each input image (png, webp or jpg, up to 16 images) is less than 50MB, but the mask field says 'Must be a valid PNG file, less than 4MB, and have the same dimensions as image'; transparent (alpha zero) areas mark where to edit and the mask applies to the first image. Reading: the guide's 50MB can be read as applying to image and mask together as a loose statement, the schema separates them, so the strict reading is image under 50 MB, mask PNG under 4 MB. The deprecated variations request also says 'less than 4MB' for a square PNG, so a 4MB figure appears in two places and may be remembered for the wrong endpoint. Failure modes. A large mask PNG (for example a 4K full-colour mask)...
Structured fields
{
"citations": [
{
"url": "https://developers.openai.com/api/docs/guides/image-generation.md",
"note": "Edit Images > Mask requirements; CreateImageEditRequest.image; CreateImageEditRequest.mask; CreateImageVariationRequest.image (deprecated); reconciliation"
},
{
"url": "https://raw.githubusercontent.com/openai/openai-openapi/master/openapi.yaml",
"note": "Edit Images > Mask requirements; CreateImageEditRequest.image; CreateImageEditRequest.mask; CreateImageVariationRequest.image (deprecated); reconciliation"
}
]
}Evidence claims
- [sourced_fact] Problem. Two numbers circulate for OpenAI edit masks: 50 MB and 4 MB. Conditions. images/edits with GPT image models. Method. The guide's 'Mask requirements' section reads 'The image to edit and mask must be of the same format and size (less than 50MB in size)'. The openapi.yaml CreateImageEditRequest says each input image (png, webp or jpg, up to 16 images) is less than 50MB, but the mask field says 'Must be a valid PNG file, less than 4MB, and have the same dimensions as image'; transparent (alpha zero) areas mark where to edit and the mask applies to the first image. Reading: the guide's 50MB can be read as applying to image and mask together as a loose statement, the schema separates them, so the strict reading is image under 50 MB, mask PNG under 4 MB. The deprecated variations request also says 'less than 4MB' for a square PNG, so a 4MB figure appears in two places and may be remembered for the wrong endpoint. Failure modes. A large mask PNG (for example a 4K full-colour mask) can exceed 4 MB even when the image is fine; the guide also says same 'format', while the schema requires PNG for the mask and allows png/webp/jpg for images, so a jpg image with a png mask is not literally the same format. Limitations. Server behaviour on a 4 to 50 MB mask was not tested. Version/date. Fetched 2026-10-24T00:55:40Z. · locator: Edit Images > Mask requirements; CreateImageEditRequest.image; CreateImageEditRequest.mask; CreateImageVariationRequest.image (deprecated); reconciliation source
Rights
| component | license | hosting | redistribution | modification | training | Evidence and notes |
|---|---|---|---|---|---|---|
| documentation | unknown | permitted | permitted | unknown | unknown | Applies to this original summary only, not to the cited sources. |