---
title: "Delete a Copilot Space for a user"
method: DELETE
path: "/users/{username}/copilot-spaces/{space_number}"
tags: ["copilot-spaces"]
---

# Delete a Copilot Space for a user

`DELETE /users/{username}/copilot-spaces/{space_number}`

Deletes a Copilot Space owned by a user. The authenticated user must be the owner of the space.

**Warning:** This action is permanent and cannot be undone. Deleting a space will remove all associated resources and configurations.

OAuth app tokens and personal access tokens (classic) need the `user` scope to use this endpoint.

## Path parameters

- `username` string, required
- `space_number` integer, required

## Response `204`

The Copilot Space has been successfully deleted.

## Other responses

- `404` — Resource not found
- `422` — Validation failed, or the endpoint has been spammed.

---

[API](https://skmtc.net/github/apis/rest-api.md) · [All operations](https://skmtc.net/github/apis/rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/rest-api/versions/80850db290cd/schema)
