---
title: thv config otel set-sampling-rate
hide_title: true
description: Reference for ToolHive CLI command `thv config otel set-sampling-rate`
last_update:
  author: autogenerated
slug: thv_config_otel_set-sampling-rate
mdx:
  format: md
---

## thv config otel set-sampling-rate

Set the OpenTelemetry sampling rate

### Synopsis

Set the OpenTelemetry trace sampling rate (between 0.0 and 1.0).

This sampling rate will be used by default when running MCP servers unless overridden by the --otel-sampling-rate flag.

Example:

	thv config otel set-sampling-rate 0.1

```
thv config otel set-sampling-rate <rate> [flags]
```

### Options

```
  -h, --help   help for set-sampling-rate
```

### Options inherited from parent commands

```
      --debug   Enable debug mode
```

### SEE ALSO

* [thv config otel](thv_config_otel.md)	 - Manage OpenTelemetry configuration

