---
title: "Resize an exec instance"
method: POST
path: "/exec/{id}/resize"
tags: ["Exec"]
---

# Resize an exec instance

`POST /exec/{id}/resize`

Resize the TTY session used by an exec instance. This endpoint only works
if `tty` was specified as part of creating and starting the exec instance.

## Path parameters

- `id` string, required

## Query parameters

- `h` integer, required
- `w` integer, required

## Response `200`

No error

## Other responses

- `400` — bad parameter
- `404` — No such exec instance
- `500` — Server error

## Changes

> 3 revisions in range; 1 could not be searched.

- **2025-02-26** `596850687f9a` — 2 info
  - the `query` request parameter `h` became optional
  - the `query` request parameter `w` became optional

[Change history](https://skmtc.dev/cloudfoundry/apis/docker-engine-api/changes/exec/:id/resize/post.md)

---

[API](https://skmtc.dev/cloudfoundry/apis/docker-engine-api.md) · [All operations](https://skmtc.dev/cloudfoundry/apis/docker-engine-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/cloudfoundry/docker-engine-api/revisions/f44c4514b589/schema)
