---
title: "Close a preview URL"
method: DELETE
path: "/sandboxes/{id}/ports/{port}"
tags: ["Ports"]
---

# Close a preview URL

`DELETE /sandboxes/{id}/ports/{port}`

## Request

- Base URL: `https://sandbox-as-a-service.com/v1`
- URL: `https://sandbox-as-a-service.com/v1/sandboxes/{id}/ports/{port}`
- Auth: HTTP bearer

The URL stops working immediately. The server inside the sandbox is left alone.

## Path parameters

- `id` string, required
- `port` integer, required

## Response `200`

Closed.

- object

## Other responses

- `404`: No open preview for that port.

---

[API](https://skmtc.dev/sandbox-as-a-service/apis/sandbox-as-a-service-api.md) · [All operations](https://skmtc.dev/sandbox-as-a-service/apis/sandbox-as-a-service-api/llms.txt) · [OpenAPI document](https://skmtc.dev/sandbox-as-a-service/apis/sandbox-as-a-service-api/revisions/4f1ea2cf8333?raw)
