---
title: "Delete a template"
method: DELETE
path: "/v2/templates/{id}"
tags: ["Templates"]
---

# Delete a template

`DELETE /v2/templates/{id}`

Permanently deletes a template by ID. Rejected if the template is
currently referenced by a pod (see that pod's `template` field) or
bound to a serverless endpoint.

## Response `204`

Deleted. Response has no body.

## Other responses

- `400` — Template is in use by a pod or serverless endpoint and cannot be deleted
- `401` — Authentication failed because the bearer token is missing, malformed, expired, or invalid.
- `403` — The bearer token is valid, but it does not grant access to the requested resource or action.
- `404` — The requested resource was not found or is not accessible to the caller.
- `429` — The caller exceeded its per-user rate limit. The response identifies the window that was exceeded and how long to wait. The `RateLimit` and `RateLimit-Policy` headers (per the IETF ratelimit-headers draft) also accompany successful responses, so clients can track quota before a 429.
- `default` — Error

---

[API](https://skmtc.dev/runpod/apis/runpod-rest-api.md) · [All operations](https://skmtc.dev/runpod/apis/runpod-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/runpod/runpod-rest-api/revisions/504cd0394ed6/schema)
