Image extension skill
Extend an image beyond its original borders, with new content generated in the added area to reach a target aspect ratio.
Use it in the browser
Upload a picture in the image extender, pick the new frame and review the result in the browser.
Open Image ExtenderCall it from your agent
Pass a public image URL and a target ratio to extend_image. 30 credits per job.
MCP toolextend_image
Connects with OAuth to your existing ImageToLayers account. No separate API key.
MCP setup guideBefore and after
A square family photo extended into a wide frame.


Sample from the ImageToLayers library. The added scenery is generated by AI, and details of the original can shift, so compare before publishing.
What this skill does
Target a new ratio
Choose 1:1, 4:5, 9:16, 16:9, 3:2 or 2:3.
Control where space is added
Nine positions set where the original sits inside the new canvas.
Guide the new area
An optional prompt describes what to generate. Without it the model continues the scene.
One PNG result
A completed MCP job returns a download link for the extended image.
Tool parameters
The inputs the MCP tool accepts.
image_urlstring (URL)RequiredPublic HTTP or HTTPS URL pointing directly to a JPG, PNG, WEBP or GIF image, up to 20 MB. Local files are not supported.
aspect_ratioenumRequiredTarget ratio of the new canvas. It must differ from the source ratio; otherwise the request is rejected without charge.
Allowed values:
1:1, 4:5, 9:16, 16:9, 3:2, 2:3positionenumOptionalWhere the original image sits in the new canvas, which decides the sides that grow.
Allowed values:
top-left, top-center, top-right, center-left, center, center-right, bottom-left, bottom-center, bottom-rightDefault:
centerpromptstring (≤1500)OptionalGuidance for the generated area. Screened against the content policy.
request_idstring (1–200)RequiredA unique ID you choose for this request. Reusing it returns the original job.
How an agent runs it
- 1
Provide image and ratio
The agent calls extend_image with a public image URL, an aspect_ratio and a request_id.
- 2
Receive a job ID
The tool checks credits and any prompt, imports the image and starts an asynchronous job.
- 3
Poll and download
The agent calls get_job until the job completes, then downloads the PNG.
Example tool call
{
"name": "extend_image",
"arguments": {
"image_url": "https://example.com/family-photo.png",
"aspect_ratio": "16:9",
"position": "center",
"prompt": "Continue the sunlit park to the left and right",
"request_id": "extend-2026-001"
}
}Connects with OAuth to your existing ImageToLayers account. No separate API key. MCP setup guide
Related skills
Image to layers
Split a flat image into separate subject, background and object layers.
View skillText to SVG
Generate a native SVG vector image from a written description.
View skillFrequently asked questions
Which aspect ratios are available?
1:1, 4:5, 9:16, 16:9, 3:2 and 2:3. Pick one that differs from your image: if the image already has that ratio, there is nothing to add and the request is rejected without charge.
Can I choose which side gets extended?
Yes. position places the original inside the new canvas. For example, center-left adds space on the right when the canvas gets wider.
Do I have to write a prompt?
No. Leave prompt out to let the model continue the scene.
Will the original pixels stay unchanged?
Do not assume so. The image can be resized to fit processing limits, and the result is AI generated, so check it against your source.
How much does one job cost?
30 credits per extension job.
How do I get the result from an agent call?
The tool returns a job_id straight away. Poll get_job with that ID until the status is completed or failed. Completed jobs include time-limited download links; call get_job again if a link has expired.
Do I need a separate account or API key for agents?
No. Your MCP client connects with OAuth to your existing ImageToLayers account.
What happens if a request is retried?
Send the same request_id. You get the original job back instead of a second charge.
AI-generated and AI-edited results may vary. Review important visual details before publishing or using outputs in production.
Give your picture more room
Extend it in the browser, or hand the task to your agent.