# TS.DELETE

> Delete a time series with all its samples, labels and rules.

URL: https://docs.hotkv.com/commands/ts-delete/

```
TS.DELETE key
```

- Group: Time series
- Complexity: O(N), N being the samples
- HotKV Cloud: Performance and Scale plans
- On-Premise: requires the time-series license feature

`TS.DELETE` removes the time series `key` with all its samples, labels and
the [TS.DOWNSAMPLE](https://docs.hotkv.com/commands/ts-downsample/index.md) rules it is the source of.
Rules on other series that write into it stay in place but have nothing to
write to until a series with that name is created again.

Use `TS.DELETE`, not [DEL](https://docs.hotkv.com/commands/del/index.md): time series are not keys in the
keyspace.

## Return value

| Case | RESP2 | RESP3 |
| --- | --- | --- |
| Deleted | Simple string `OK` | Simple string `OK` |

Error replies: `ERR series not found`, and `NOLICENSE ...` without the
`time-series` license feature.

## Examples

```
127.0.0.1:6379> TS.CREATE temp:kitchen
OK
127.0.0.1:6379> TS.DELETE temp:kitchen
OK
127.0.0.1:6379> TS.DELETE temp:kitchen
(error) ERR series not found
```

## Compatibility

HotKV-only command. In RedisTimeSeries, `TS.DEL` deletes samples in a range
and `DEL` deletes the series; in HotKV, `TS.DELETE` deletes the whole series.

## See also

[TS.CREATE](https://docs.hotkv.com/commands/ts-create/index.md), [TS.LIST](https://docs.hotkv.com/commands/ts-list/index.md), [TS.RETENTION](https://docs.hotkv.com/commands/ts-retention/index.md)