For AI agents: A markdown version of this page is available at https://docs.datadoghq.com/tracing/trace_collection/library_config/python.md. A documentation index is available at /llms.txt.

After you set up the SDK with your code and configure the Agent to collect APM data, optionally configure the SDK as desired, including setting up Unified Service Tagging.

To verify your runtime configuration and confirm settings, view the current configuration of your service in Datadog. Navigate to the APM Service Page, click Service Config, and select the SDK Configuration tab.

When using ddtrace-run, the following environment variable options can be used:

Configuration keys

490 configuration keys available for this library.

General Settings

(27)

Top-level Datadog configuration: API keys, service identity, Agent connection, intake site, hostname, global tags, and proxy settings.

DD_AGENT_HOST
Type: string
Overrides the default trace Agent host address for trace submission. Ignored if DD_TRACE_AGENT_URL is set.
DD_API_KEY
Type: string
Aliases:DATADOG_API_KEY
Sets the Datadog API key used to authenticate outbound requests when running in agentless mode (sending data directly to Datadog without a local Agent). Required for agentless CI test reporting and LLM Observability agentless mode.
DD_APM_FLUSH_DEADLINE_MILLISECONDS
Type: int
Default: 100
Doesn’t crash when spans are finished early and reached impending timeout
DD_APM_TRACING_ENABLED
Type: boolean
Default: true
Aliases:DD_TRACING_ENABLED
Enables or disables sending APM trace data. When disabled, tracing still runs to support other products, but only periodic heartbeat traces and manually kept traces are sent.
DD_APP_KEY
Type: string
Sets the application key used to authenticate LLM Observability dataset and experiment requests in agentless mode. If agentless mode is enabled and this is not set, dataset/experiment operations that require an application key will fail.
DD_CARGO_ARGS
Type: string
Extra command-line arguments passed to cargo when building the bundled native Rust extension at install time. The value is shell-split (so multiple flags can be provided, e.g. --locked --offline) and forwarded directly to the Rust build. When unset, no additional arguments are passed.
DD_DURABLE_CROSS_INVOCATION_TRACING_ENABLED
Type: boolean
Default: true

Controls whether the AWS Durable Execution SDK integration persists trace context across suspend/resume invocations of the same durable execution.

When enabled (the default), the integration installs a hook on the SDK’s termination manager. Whenever a workflow suspends with a non-terminal reason (e.g. CALLBACK_PENDING), the current trace context is saved as a synthetic _datadog_{N} STEP operation on the execution state. The upstream Datadog Lambda wrapper consumes this checkpoint on the resumed invocation so the resumed aws.durable.execute span continues the same trace instead of starting a disconnected one.

DD_ENTITY_ID
Type: string
Identifies the client entity (typically the Kubernetes pod UID) sending metrics through the embedded DogStatsD client. When set, its value is attached to outgoing metrics as the dd.internal.entity_id tag so the Agent can enrich them with the right pod/container tags, and the client will not send a container ID alongside it. When unset, the client falls back to container-ID origin detection (controlled by DD_ORIGIN_DETECTION_ENABLED).
DD_ENV
Type: string
Sets the global env tag applied to all telemetry emitted by the tracer (traces, metrics, logs, profiles). Use it to separate environments such as prod, staging, or dev.
DD_EXTERNAL_ENV
Type: string
Sets an external environment identifier attached to emitted telemetry for origin and environment attribution.
DD_FFE_INTAKE_ENABLED
Type: boolean
Default: true
Controls whether the OpenFeature integration sends feature flag exposure events to the Datadog Agent’s EVP proxy endpoint. When enabled (the default), the exposure writer reports each evaluated feature flag exposure for analysis in Datadog. Set to a falsy value to disable exposure reporting while keeping the rest of the OpenFeature integration active.
DD_HOSTNAME
Type: string
Overrides the hostname used for tagging and telemetry when hostname auto-detection is unreliable. The value must be a valid hostname; invalid values are ignored and hostname auto-detection is used instead.
DD_LAMBDA_HANDLER
Type: string
  • Set the environment variable DD_LAMBDA_HANDLER to your original handler, for example, myfunc.handler.
DD_LIVE_DEBUGGING_ENABLED
Type: boolean
Default: false
Enables the Live Debugger, allowing dynamic instrumentation to capture runtime data from your running application without redeploying. When unset, the Live Debugger is disabled.
DD_MAIN_PACKAGE
Type: string
Names the primary Python package of your application. When set, the tracer reads that package’s metadata (e.g. its Project-URL: source_code_link entry) to derive the repository URL and commit SHA used for Source Code Integration tagging, and the profiler uses it to mark frames from that package as user code in code provenance. Used as a fallback when DD_GIT_REPOSITORY_URL and DD_GIT_COMMIT_SHA are not set. When unset, no package-based git metadata lookup is performed.
DD_ML_JOB_ENV
Type: map
Semicolon-separated KEY:VALUE pairs forwarded verbatim into Ray job worker environments. Use this to propagate ddtrace configuration (e.g. DD_SERVICE:my-svc;DD_AGENT_HOST:10.0.0.1) to workers launched by the Ray job submission API.
DD_MODEL_LAB_ENABLED
Type: boolean
Default: false
When enabled, automatically activates the MLflow integration (equivalent to setting DD_TRACE_MLFLOW_ENABLED=true) and turns on MLflow log injection by default. If DD_API_KEY and DD_APP_KEY are also set, the MLflow authentication plugin injects DD-API-KEY and DD-APPLICATION-KEY headers into outgoing MLflow tracking-server requests so they can be authenticated against Datadog’s Model Lab.
DD_PATCH_MODULES
Type: string
Comma-separated overrides controlling which integrations are auto-patched when ddtrace.auto is imported (or ddtrace-run is used). Each entry uses the form <integration>:<bool>, for example DD_PATCH_MODULES="redis:true,requests:false". Entries here override the default per-integration patch behavior, letting you enable integrations that are off by default or disable ones that are on by default. Integration names match the names used by ddtrace integrations (e.g. redis, kombu, httplib, urllib3, ray).
DD_SCCACHE_PATH
Type: string
Absolute path to the sccache binary used to cache C/C++ and Rust compiler invocations when building the native extensions. When set, the build passes it to CMake as the C and C++ compiler launcher to speed up rebuilds. When unset, no compiler caching launcher is configured and sources are compiled directly.
DD_SERVERLESS_BUILD
Type: boolean
Default: false
When enabled, builds a serverless-flavored wheel by appending a -serverless suffix to the package name and excluding the crashtracker and ffe Rust features from the native extension. Used to produce slimmer artifacts intended for serverless environments.
DD_SERVICE
Type: string
Aliases:DD_SERVICE_NAME, OTEL_SERVICE_NAME

Sets the service name used as the service tag on every span. If not specified, the SDK tries to determine the service name automatically.

Language-specific notes:

  • .NET: falls back to the IIS application name, process entry assembly, or process name.
  • Java: falls back to the Java agent’s auto-detected service name based on the application class.
  • Node.js: falls back to the name field in package.json.
DD_SERVICE_MAPPING
Type: map
Provide service names for each plugin. Accepts comma separated plugin:service-name pairs, with or without spaces.
DD_SITE
Type: string
Default: datadoghq.com
Sets the site domain used to build agentless intake URLs. If unset, a default site is used.
DD_TAGS
Type: map
Aliases:OTEL_RESOURCE_ATTRIBUTES
Custom tags applied to traces, provided as comma-separated key:value pairs (e.g. layer:api,team:intake).
DD_TESTING_RAISE
Type: boolean
Default: false
When enabled, internal ddtrace errors that are normally swallowed to keep your application running are re-raised instead. This currently affects exceptions thrown by atexit handlers and exit-signal handlers registered by the tracer, which surface as real exceptions (or stderr tracebacks) rather than being silently ignored. Intended for testing and debugging the tracer itself; leave disabled in production.
DD_USE_SCCACHE
Type: boolean
Default: false
When enabled, uses sccache to cache and accelerate compilation of the tracer’s native (C/C++/Rust) extensions during build. Useful for frequent rebuilds or multi-container deployments. Requires sccache to be installed and discoverable via PATH or the SCCACHE_PATH / SCCACHE environment variables. Defaults to disabled.
DD_VERSION
Type: string

Sets the application’s version, used as the version tag in traces and logs (for example: 1.2.3, 6c44da20, 2020.02.13).

Language-specific notes:

  • PHP: starting with version 0.90.0, changes made at runtime through ini_set('datadog.version', ...) are also applied to the current root span.

Tracing Core

(38)

Core distributed tracing engine: Agent connection, trace and span ID generation, span lifecycle management, peer service mapping, resource normalization, query string obfuscation, and DB client configuration.

DD_TRACE_128_BIT_TRACEID_GENERATION_ENABLED
Type: boolean
Default: true
Controls whether the tracer generates 128-bit W3C trace IDs (32-character hex) or 64-bit Datadog trace IDs (16-character hex). 128-bit IDs are required for full W3C traceparent interoperability.
DD_TRACE_128_BIT_TRACEID_LOGGING_ENABLED
Type: boolean
Default: false
Controls whether 128-bit trace IDs are logged in their full 32-character format or truncated to 16 characters. Set to false for compatibility with systems that expect the shorter format.
DD_TRACE_AGENT_HOSTNAME
Type: string
Sets the hostname of the Datadog Agent that the tracer submits traces to. Takes precedence over DD_AGENT_HOST when both are set, and is ignored if DD_TRACE_AGENT_URL is provided. When unset, the tracer falls back to DD_AGENT_HOST, then to the Unix socket at /var/run/datadog/apm.socket if available, and finally to localhost.
DD_TRACE_AGENT_PORT
Type: int
Default: 8126
The port of the Trace Agent that the tracer submits to. If the Agent configuration sets receiver_port or DD_APM_RECEIVER_PORT to something other than the default 8126, then DD_TRACE_AGENT_PORT or DD_TRACE_AGENT_URL must match it.
DD_TRACE_AGENT_PROTOCOL_VERSION
Type: string
Default: 0.4
Protocol version to use for requests to the agent. The version configured must be supported by the agent version installed or all traces will be dropped.
DD_TRACE_AGENT_TIMEOUT_SECONDS
Type: decimal
Default: 2.0
Timeout (in seconds) for connecting to the Datadog Agent when sending trace data.
DD_TRACE_AGENT_URL
Type: string
URL endpoint where this library sends trace data to the Datadog Agent. Can use HTTP or a Unix domain socket. Has priority over agent.host and agent.port. If the Agent configuration sets receiver_port or DD_APM_RECEIVER_PORT to something other than the default 8126, then DD_TRACE_AGENT_PORT or DD_TRACE_AGENT_URL must match it.
DD_TRACE_API_VERSION
Type: string
Selects the trace API version used to encode and send traces to the Datadog agent. Supported values are v0.4 and v0.5 (v0.3 is no longer supported and is ignored). When unset, the tracer uses v0.5, except on Windows, in GCP or Azure Functions, or when ASM, IAST, or AI Guard is enabled, where it falls back to v0.4.
DD_TRACE_CLIENT_IP_ENABLED
Type: boolean
Default: false
Enables or disables the automatic collection of client IP addresses from HTTP request headers. When enabled, the IP address is stored in the http.client_ip span tag.
DD_TRACE_CLIENT_IP_HEADER
Type: string
Name of an optional custom HTTP header used to resolve the client IP address.
DD_TRACE_CLOUD_PAYLOAD_TAGGING_MAX_DEPTH
Type: int
Default: 10
An integer representing the maximum depth of an AWS SDK request/reponse payload to use for AWS payload tagging.
DD_TRACE_CLOUD_PAYLOAD_TAGGING_MAX_TAGS
Type: int
Default: 758
An integer representing the maximum number of tags to extract per a span to be used for AWS payload tagging.
DD_TRACE_CLOUD_PAYLOAD_TAGGING_SERVICES
Type: string
Default: s3,sns,sqs,kinesis,eventbridge,dynamodb
To enable AWS payload tagging for additional services, use this setting.
DD_TRACE_CLOUD_REQUEST_PAYLOAD_TAGGING
Type: string
A comma-separated string of JSONPath entries to redact from AWS SDK requests. Setting this enables AWS payload tagging for requests.
DD_TRACE_CLOUD_RESPONSE_PAYLOAD_TAGGING
Type: string
A comma-separated string of JSONPath entries to redact from AWS SDK responses. Setting this enables AWS payload tagging for responses.
DD_TRACE_ENABLED
Type: boolean
Default: true
Aliases:OTEL_TRACES_EXPORTER
Enables or disables tracing. When disabled, instrumentation still runs but no trace data is sent.
DD_TRACE_EXPERIMENTAL_FEATURES_ENABLED
Type: string
Supported Input: A comma-separated list of configuration options that support experimental features. Supported Values: all, DD_TAGS (Java, .NET) Caveats: Only supported in Java and .NET Description: Enables experimental features for specific configuration options. When enabled, these features may provide additional functionality but are not yet considered stable and may change or be removed in future releases. You can enable all experimental features using the keyword all, or list individual features explicitly.
DD_TRACE_HEALTH_METRICS_ENABLED
Type: boolean
Default: false
When set to true sends tracer health metrics
DD_TRACE_METHODS
Type: string

List of methods to trace. Accepts a semicolon (;) separated list where each entry has the format Namespace.TypeName[MethodNames], where MethodNames is either a comma (,) separated list of method names or the * wildcard.

For generic types, replace the angled brackets and the type parameters’ names with a backtick (`) followed by the number of generic type parameters. For example, Dictionary<TKey, TValue> must be written as Dictionary`2. For generic methods, you only need to specify the method name.

Note: The wildcard method support ([*]) selects all methods in a type except constructors, property getters and setters, Equals, Finalize, GetHashCode, and ToString

DD_TRACE_NATIVE_SPAN_EVENTS
Type: boolean
Default: false
Encode span events in the native span_events payload format instead of meta.events JSON.
DD_TRACE_OBFUSCATION_QUERY_STRING_REGEXP
Type: string
Aliases:DD_OBFUSCATION_QUERY_STRING_REGEXP
A regex to redact sensitive data from incoming requests’ query string reported in the http.url tag (matches are replaced with ).
DD_TRACE_PARTIAL_FLUSH_ENABLED
Type: boolean
Default: true
Enables incrementally flushing large traces to the Datadog Agent, reducing the chance of rejection by the Agent. Use only when you have long-lived traces or traces with many spans. Valid values are true or false. Added in version 1.26.0, only compatible with the Datadog Agent 7.26.0+.
DD_TRACE_PARTIAL_FLUSH_MIN_SPANS
Type: int
Default: 300
Minimum number of spans in a trace before partial flush is triggered.
DD_TRACE_PEER_SERVICE_DEFAULTS_ENABLED
Type: boolean
Default: false
When enabled, the tracer computes default peer.service values for eligible spans using the v1 peer-service default algorithm under Naming Schema v0. When disabled, Naming Schema v0 leaves peer.service unset.
DD_TRACE_PEER_SERVICE_MAPPING
Type: map
Maps detected peer service names to normalized values before they are attached to spans.
DD_TRACE_REMOVE_INTEGRATION_SERVICE_NAMES_ENABLED
Type: boolean
Default: false
When enabled, integrations under Naming Schema v0 stop using inferred service names and fall back to the application service name. Use this to make all spans report under DD_SERVICE regardless of integration.
DD_TRACE_REPORT_HOSTNAME
Type: boolean
Default: false
Whether to report the system’s hostname for each trace. When disabled, the hostname of the Agent is used instead.
DD_TRACE_RESOURCE_RENAMING_ALWAYS_SIMPLIFIED_ENDPOINT
Type: boolean
Default: false
When enabled, always sets the http.endpoint tag to the result of the Resource Renaming simplification algorithm, even when an explicit endpoint is available.
DD_TRACE_RESOURCE_RENAMING_ENABLED
Type: boolean
Default: false
Controls whether the http.endpoint tag is computed and added for incoming HTTP requests. This is disabled by default unless application security is enabled at startup, and can be explicitly enabled or disabled with this setting.
DD_TRACE_SPAN_ATTRIBUTE_SCHEMA
Type: string
Default: v0
Selects the span attribute and naming schema version used by integrations. Accepted values: v0, v1.
DD_TRACE_SPAN_TRACEBACK_MAX_SIZE
Type: int
Default: 30
Sets the maximum number of stack frames included in tracebacks attached to spans, including exception tracebacks recorded on errored spans. When a traceback is longer than this limit, the most recent frames are kept and older frames are dropped. Defaults to 30.
DD_TRACE_STATS_COMPUTATION_ENABLED
Type: boolean
Default: true
Aliases:DD_TRACE_TRACER_METRICS_ENABLED, DD_TRACE_COMPUTE_STATS
Controls whether client-side trace statistics computation is enabled. Defaults to true for newer versions of Python (3.14+) or when running on Serverless
DD_TRACE_WRAP_SPAN_NAME_INCLUDE_CLASS
Type: boolean
Default: false
When enabled, the default span name produced by @tracer.wrap() on methods includes the class name (e.g. module.ClassName.method) instead of just module.method. When unset or disabled, the legacy plain-name format is used and a deprecation warning is emitted; this behavior will become the default in 5.0.0.
DD_TRACE_WRITER_BUFFER_SIZE_BYTES
Type: int
Default: 20971520
Sets the maximum size, in bytes, of the in-memory buffer used by the trace writer to hold encoded traces before they are flushed to the Datadog Agent. When the buffer is full, new traces are dropped until space is available. Defaults to 20971520 (20 MB) when unset.
DD_TRACE_WRITER_INTERVAL_SECONDS
Type: decimal
Default: 1.0
Sets the interval, in seconds, at which the trace writer flushes buffered traces to the Datadog Agent. Lower values send traces more frequently at the cost of additional overhead; higher values batch more traces per flush. When unset, defaults to 1.0 second.
DD_TRACE_WRITER_MAX_PAYLOAD_SIZE_BYTES
Type: int
Default: 20971520
Sets the maximum size in bytes of a single trace payload sent to the Datadog Agent. When a buffered payload would exceed this limit, the writer flushes early to keep requests under the cap. Defaults to 20971520 (20 MB).
DD_TRACE_WRITER_REUSE_CONNECTIONS
Type: boolean
Default: false
When enabled, the trace writer reuses a single HTTP connection (keep-alive) for sending trace payloads to the Datadog Agent instead of opening a new connection for each flush. Disabled by default; set to true to reduce connection-establishment overhead at the cost of holding a persistent socket to the Agent.
DD_TRACE_X_DATADOG_TAGS_MAX_LENGTH
Type: int
Default: 512
Maximum length of the x-datadog-tags header for trace tag propagation. Set to 0 to disable.

Trace Sampling

(6)

Sampling rules and rates that determine which traces and spans are kept or dropped, including per-service rules, rate limiting, and priority sampling.

DD_SPAN_SAMPLING_RULES
Type: string
Span sampling: JSON rules used to decide per-span sampling priority (single-span sampling). If both DD_SPAN_SAMPLING_RULES and DD_SPAN_SAMPLING_RULES_FILE are set, the file setting is ignored. Rules can match spans by service/name and apply a sample rate and optional max-per-second limit.
DD_SPAN_SAMPLING_RULES_FILE
Type: string
Points to a JSON file that contains the span sampling rules. DD_SPAN_SAMPLING_RULES takes precedence over this variable. See DD_SPAN_SAMPLING_RULES for the rule format.
DD_TRACE_RATE_LIMIT
Type: int
Default: 100
Sets the maximum number of traces to sample per second; applies only when either DD_TRACE_SAMPLING_RULES or DD_TRACE_SAMPLE_RATE is set.
DD_TRACE_SAMPLE_RATE
Type: decimal
Aliases:OTEL_TRACES_SAMPLER
Controls the ingestion sample rate (between 0.0 and 1.0) between the Agent and the backend. Use OTEL_TRACES_SAMPLER as an alias
DD_TRACE_SAMPLING_RULES
Type: string
JSON array of sampling rules. The rule is matched in order of specification. The first match in a list is used. Per entry: The item “sample_rate” is required in decimal format. The item “service” is optional in regular expression format, to match on service name. The item “name” is optional in regular expression format, to match on operation name. To give a rate of 50% to any traces in a service starting with the text “cart”: ‘[{“sample_rate”:0.5, “service”:“cart.”}]’ To give a rate of 20% to any traces which have an operation name of “http.request”: ‘[{“sample_rate”:0.2, “name”:“http.request”}]’ To give a rate of 100% to any traces within a service named “background” and with an operation name of “sql.query”: ‘[{“sample_rate”:1.0, “service”:“background”, “name”:“sql.query”}] To give a rate of 10% to all traces ‘[{“sample_rate”:0.1}]’ To configure multiple rules, separate by semi-colon and order from most specific to least specific: ‘[{“sample_rate”:0.5, “service”:“cart.”}, {“sample_rate”:0.2, “name”:“http.request”}, {“sample_rate”:1.0, “service”:“background”, “name”:“sql.query”}, {“sample_rate”:0.1}]’ If no rules are specified, or none match, default internal sampling logic will be used.
DD_TRACE_WEBSOCKET_MESSAGES_INHERIT_SAMPLING
Type: boolean
Default: true
By default, websocket messages preserve the same sampling as the span captured during the handshake. This ensures that, if a handshake span has been sampled, all the messages in its session will also be sampled. To disable that behavior and sample each websocket message independently, set this configuration to false.

Trace Propagation

(11)

Distributed trace context propagation, extraction and injection behavior, baggage handling, header tagging, HTTP client and server configuration, and SQL comment injection for Database Monitoring.

DD_EXPERIMENTAL_PROPAGATE_PROCESS_TAGS_ENABLED
Type: boolean
Default: true
Controls whether process-level tags (such as entrypoint metadata) are collected and attached to tracing payloads.
DD_HTTP_SERVER_TAG_QUERY_STRING
Type: boolean
Default: true
Enables or disables reporting the query string on server spans. Default value is true.
DD_TRACE_BAGGAGE_TAG_KEYS
Type: array
Default: user.id, session.id, account.id
Comma-separated list of baggage keys to copy into span tags. Set to * to tag all baggage items; if unset, a default allowlist is used.
DD_TRACE_HEADER_TAGS
Type: map
Automatically apply specified HTTP headers as span tags. If a custom tag name is not specified, the tag key defaults to http.request.headers. for request headers and http.response.headers. for response headers.
DD_TRACE_HTTP_CLIENT_TAG_QUERY_STRING
Type: boolean
Default: true
Aliases:DD_HTTP_CLIENT_TAG_QUERY_STRING
By default, query string parameters and fragments are added to the http.url tag on web client spans. Set to false to prevent the collection of this data.
DD_TRACE_HTTP_SERVER_ERROR_STATUSES
Type: string
Default: 500-599
Aliases:DD_HTTP_SERVER_ERROR_STATUSES
Comma-separated list of HTTP status codes or ranges treated as errors for HTTP server spans (for example, 500-599,404). Overrides the default behavior of flagging only 5xx responses as errors.
DD_TRACE_INFERRED_PROXY_SERVICES_ENABLED
Type: boolean
Default: false
Aliases:DD_TRACE_INFERRED_SPANS_ENABLED
When enabled, the tracer registers the inferred-proxy propagator, which reads x-dd-proxy* headers (currently x-dd-proxy=aws-apigateway) and starts an inferred proxy span as the parent of the server span, using header values for service, resource, and tags.
DD_TRACE_PROPAGATION_BEHAVIOR_EXTRACT
Type: string
Default: continue
Specifies how incoming distributed tracing headers should be handled at a service level. Accepted values are: continue: The SDK will continue the distributed trace if the incoming distributed tracing headers represent a valid trace context. restart: The SDK will always start a new trace. If the incoming distributed tracing headers represent a valid trace context, that trace context will be represented as a span link on service entry spans (as opposed to the parent span in the continue configuration). ignore: The SDK will always start a new trace and all incoming distributed tracing headers are ignored.
DD_TRACE_PROPAGATION_EXTRACT_FIRST
Type: boolean
Default: false
When set to true, stops extracting after the first successful trace context extraction.
DD_TRACE_PROPAGATION_STYLE_EXTRACT
Type: array
Default: datadog,tracecontext,baggage
Aliases:DD_PROPAGATION_STYLE_EXTRACT, DD_TRACE_PROPAGATION_STYLE
A comma-separated list of header formats from which to attempt to extract distributed tracing propagation data. The first format found with complete and valid headers is used to define the trace to continue.
DD_TRACE_PROPAGATION_STYLE_INJECT
Type: array
Default: datadog,tracecontext,baggage
Aliases:DD_PROPAGATION_STYLE_INJECT, DD_TRACE_PROPAGATION_STYLE
A comma-separated list of header formats to include to propagate distributed traces between services. The first format found with complete and valid headers is used to define the trace to continue.

Trace Integrations

(211)

Per-integration tracing configuration: enable/disable, analytics, service name, peer service overrides for library integrations and controls for disabling specific instrumentations.

Configuration Kinds

Each integration can support one or more of these configuration patterns. Replace <INTEGRATION> with the integration name (for example, GRPC, AWS, REDIS).

DD_TRACE_<INTEGRATION>_ENABLED

(99 integrations)

DD_<INTEGRATION>_SERVICE

(99 integrations)

Per-Integration Settings (115 integrations)

Each section lists all configuration keys available for a specific integration.

AIOBOTOCORE

(2)
DD_AIOBOTOCORE_SERVICE
Type: string
Aliases:DD_AIOBOTOCORE_SERVICE_NAME
Sets the service name reported for AWS calls traced by the aiobotocore integration. When unset, spans fall back to a service name derived from the AWS endpoint being called (e.g. aws.s3, aws.sqs).
DD_TRACE_AIOBOTOCORE_ENABLED
Type: boolean
Default: false
Controls whether the aiobotocore integration is enabled when ddtrace auto-instruments your application. When set to true, calls made through aiobotocore clients are traced and reported to Datadog. When unset or false, the integration is not patched and no aiobotocore spans are produced.

AIOHTTP

(2)
DD_AIOHTTP_SERVICE
Type: string
Aliases:DD_AIOHTTP_SERVICE_NAME
Sets the service name reported for aiohttp server traces produced by the aiohttp integration. When unset, traces fall back to the default service name "aiohttp-web".
DD_TRACE_AIOHTTP_ENABLED
Type: boolean
Default: true
Controls whether the aiohttp integration is automatically patched when tracing is enabled. When set to a falsy value, aiohttp server requests and middleware will not be instrumented and no spans will be produced for the integration. When unset, the integration is enabled by default.

AIOHTTP_CLIENT

(1)
DD_AIOHTTP_CLIENT_SERVICE
Type: string
Aliases:DD_AIOHTTP_CLIENT_SERVICE_NAME
Sets the service name reported for outbound HTTP client traces produced by the aiohttp integration. When unset, traces fall back to the globally configured service name.

AIOHTTP_JINJA2

(1)
DD_TRACE_AIOHTTP_JINJA2_ENABLED
Type: boolean
Default: true
Controls whether the aiohttp_jinja2 integration is enabled. When enabled, template rendering performed via aiohttp_jinja2.render_template is automatically traced. When disabled, no spans are produced for template rendering in aiohttp applications using aiohttp_jinja2.

AIOKAFKA

(2)
DD_AIOKAFKA_SERVICE
Type: string
Default: kafka
Aliases:DD_AIOKAFKA_SERVICE_NAME
Sets the service name reported by default for traces produced by the aiokafka integration. When unset, traces fall back to the default service name "kafka".
DD_TRACE_AIOKAFKA_ENABLED
Type: boolean
Default: true
Controls whether the aiokafka integration is enabled. When enabled, ddtrace automatically instruments aiokafka producers and consumers to produce spans for send, getone, getmany, and offset commit operations. Disable to stop tracing aiokafka calls without removing the integration.

AIOMYSQL

(2)
DD_AIOMYSQL_SERVICE
Type: string
Default: mysql
Aliases:DD_AIOMYSQL_SERVICE_NAME
Sets the service name reported by default for traces produced by the aiomysql integration. When unset, traces fall back to the default service name "mysql".
DD_TRACE_AIOMYSQL_ENABLED
Type: boolean
Default: true
Controls whether the aiomysql integration is auto-patched, which traces MySQL queries issued through the aiomysql async client. When unset, the integration is enabled by default; set to a falsy value to disable tracing for aiomysql.

AIOPG

(2)
DD_AIOPG_SERVICE
Type: string
Default: postgres
Aliases:DD_AIOPG_SERVICE_NAME
Sets the service name reported for spans produced by the aiopg integration. When unset, traces fall back to the default service name "postgres".
DD_TRACE_AIOPG_ENABLED
Type: boolean
Default: true
Controls whether the aiopg integration is enabled, producing a span for each Postgres query executed through aiopg. When set to false, the integration is not patched and no aiopg spans are emitted. Enabled by default.

ALGOLIASEARCH

(2)
DD_ALGOLIASEARCH_SERVICE
Type: string
Aliases:DD_ALGOLIASEARCH_SERVICE_NAME
Sets the service name reported by default for Algoliasearch traces produced by the algoliasearch integration. When unset, traces fall back to the default service name "algoliasearch".
DD_TRACE_ALGOLIASEARCH_ENABLED
Type: boolean
Default: true
Controls whether the algoliasearch integration is automatically patched to produce traces for Algolia search client calls. When enabled (the default), search operations performed via the algoliasearch library are instrumented and reported under the algoliasearch service. Set to false to disable instrumentation of this library.

ANTHROPIC

(2)
DD_ANTHROPIC_SERVICE
Type: string
Aliases:DD_ANTHROPIC_SERVICE_NAME
Sets the service name reported by default for traces produced by the anthropic integration. When unset, traces fall back to the global service name.
DD_TRACE_ANTHROPIC_ENABLED
Type: boolean
Default: true
Enables instrumentation for anthropic. When disabled, spans for anthropic operations are not created.

AREDIS

(2)
DD_AREDIS_SERVICE
Type: string
Default: redis
Aliases:DD_AREDIS_SERVICE_NAME
Sets the service name reported by default for traces produced by the aredis integration. When unset, traces fall back to the default service name "redis".
DD_TRACE_AREDIS_ENABLED
Type: boolean
Default: true
Controls whether the aredis integration is automatically patched on import to trace async Redis client calls. When enabled (the default), aredis commands are instrumented and produce spans tagged with command, host, and port information. Set to false to disable automatic patching of aredis.

ASGI

(1)
DD_ASGI_SERVICE
Type: string
Default: asgi
Aliases:DD_ASGI_SERVICE_NAME
Sets the service name reported by the asgi integration for traces produced by ASGI-based applications. When unset, the integration falls back to DD_ASGI_SERVICE_NAME and then to the global service name.

ASYNCIO

(2)
DD_ASYNCIO_SERVICE
Type: string
Aliases:DD_ASYNCIO_SERVICE_NAME
Sets the service name reported by the asyncio integration. When unset, the integration falls back to DD_ASYNCIO_SERVICE_NAME and then to the global service name.
DD_TRACE_ASYNCIO_ENABLED
Type: boolean
Default: true
Controls whether the asyncio integration is patched on import to trace concurrent execution of asyncio.Task. When enabled (the default), tasks created via the event loop are instrumented so spans propagate context across them. Set to a falsy value to disable asyncio task instrumentation while leaving other integrations unaffected.

ASYNCPG

(2)
DD_ASYNCPG_SERVICE
Type: string
Default: postgres
Aliases:DD_ASYNCPG_SERVICE_NAME
Sets the service name reported for traces produced by the asyncpg integration. When unset, traces fall back to the default service name "postgres".
DD_TRACE_ASYNCPG_ENABLED
Type: boolean
Default: true
Controls whether the asyncpg integration is enabled, which traces PostgreSQL database requests made through asyncpg connection and cursor objects. When enabled (the default), asyncpg is auto-patched on tracer startup; set to false to disable instrumentation for this library.

AVRO

(2)
DD_AVRO_SERVICE
Type: string
Aliases:DD_AVRO_SERVICE_NAME
Sets the service name reported by the avro integration, which traces Avro read/write calls made with the avro library. When unset, the integration falls back to DD_AVRO_SERVICE_NAME and then to the global service name.
DD_TRACE_AVRO_ENABLED
Type: boolean
Default: true
Aliases:DD_INTEGRATION_AVRO_ENABLED, DD_TRACE_INTEGRATION_AVRO_ENABLED
Enables AVRO instrumentation

AWS_LAMBDA

(2)
DD_AWS_LAMBDA_SERVICE
Type: string
Aliases:DD_AWS_LAMBDA_SERVICE_NAME
Sets the service name reported by the aws_lambda integration. When unset, the integration falls back to DD_AWS_LAMBDA_SERVICE_NAME and then to the global service name.
DD_TRACE_AWS_LAMBDA_ENABLED
Type: boolean
Default: true
Aliases:DD_TRACE_INTEGRATION_AWS_LAMBDA_ENABLED, DD_INTEGRATION_AWS_LAMBDA_ENABLED
Enables AWS Lambda (LambdaHandler) instrumentation

AZURE_COSMOS

(2)
DD_AZURE_COSMOS_SERVICE
Type: string
Aliases:DD_AZURE_COSMOS_SERVICE_NAME
Sets the service name reported by the azure_cosmos integration for spans created around azure.cosmos (sync and async) client operations. When unset, traces fall back to the global service name.
DD_TRACE_AZURE_COSMOS_ENABLED
Type: boolean
Default: true
Enables instrumentation of the Azure CosmosDB SDK in the tracers. Instrumentation is enabled by default.

AZURE_DURABLE_FUNCTIONS

(1)
DD_TRACE_AZURE_DURABLE_FUNCTIONS_ENABLED
Type: boolean
Default: true
Enables or disables durable-functions tracing

AZURE_EVENTHUBS

(2)
DD_AZURE_EVENTHUBS_SERVICE
Type: string
Default: azure_eventhubs
Aliases:DD_AZURE_EVENTHUBS_SERVICE_NAME
Sets the service name reported by the azure_eventhubs integration for spans produced when patching the azure.eventhub and azure.eventhub.aio clients. When unset, traces fall back to the default service name "azure_eventhubs" (subject to schematization).
DD_TRACE_AZURE_EVENTHUBS_ENABLED
Type: boolean
Default: true
Controls whether the azure_eventhubs integration is enabled, instrumenting the azure.eventhub and azure.eventhub.aio clients to produce spans for Event Hubs producer operations. When unset, the integration is enabled by default. Set to a falsy value to disable Event Hubs tracing while leaving other integrations unaffected.

AZURE_FUNCTIONS

(1)
DD_AZURE_FUNCTIONS_SERVICE
Type: string
Default: azure_functions
Aliases:DD_AZURE_FUNCTIONS_SERVICE_NAME
Sets the service name reported by the azure_functions integration for traces produced by your Azure Function app. When unset, traces fall back to the default service name "azure_functions".

AZURE_SERVICEBUS

(1)
DD_TRACE_AZURE_SERVICEBUS_ENABLED
Type: boolean
Default: true
Controls whether the azure_servicebus integration is enabled. When enabled (the default), ddtrace patches azure.servicebus (and its azure.servicebus.aio async counterpart) to produce spans for sending, scheduling, and batching messages on Service Bus producers, and to inject distributed-tracing context into outgoing messages. Set to a falsy value to disable instrumentation of the azure-servicebus SDK.

BOTO

(2)
DD_BOTO_SERVICE
Type: string
Aliases:DD_BOTO_SERVICE_NAME
Sets the service name reported by the boto integration for spans tracing AWS API calls. When unset, traces fall back to a default service name derived from the integration’s pin (aws) combined with the AWS endpoint being called (for example, aws.s3).
DD_TRACE_BOTO_ENABLED
Type: boolean
Default: true
Controls whether the boto integration is automatically patched at startup. When set to false, calls made through the legacy AWS boto client library are not traced. Enabled by default.

BOTOCORE

(3)
DD_BOTOCORE_EMPTY_POLL_ENABLED
Type: boolean
Default: true
Controls whether the botocore integration instruments empty poll calls to AWS SQS and Kinesis (i.e. ReceiveMessage / GetRecords calls that return no messages or records). When enabled (the default), spans are produced for every poll, including empty ones. When disabled, polls that return no messages are not traced, which can reduce span volume in services that long-poll high-throughput queues.
DD_BOTOCORE_PROPAGATION_ENABLED
Type: boolean
Default: false
When enabled, the botocore integration extracts upstream Datadog trace context from incoming SQS ReceiveMessage and Kinesis GetRecords payloads, linking the consumer span to the producer trace. When disabled (default), inbound messages start a new trace even if they carry propagated context.
DD_TRACE_BOTOCORE_ENABLED
Type: boolean
Default: true
Controls whether the botocore integration is automatically patched and traces are produced for AWS SDK calls made via botocore (and boto3). When enabled, calls to AWS services such as S3, DynamoDB, SQS, SNS, Lambda, and others are traced. When disabled, no spans are emitted for botocore operations. Accepts standard boolean values; defaults to enabled.

BOTTLE

(2)
DD_BOTTLE_SERVICE
Type: string
Default: bottle
Aliases:DD_BOTTLE_SERVICE_NAME
Sets the service name reported for traces produced by the bottle integration. When unset, traces fall back to the global service name and then to the default service name "bottle".
DD_TRACE_BOTTLE_ENABLED
Type: boolean
Default: true
Controls whether the bottle integration is automatically patched at startup. When enabled (the default), incoming requests handled by Bottle applications are traced. Set to false to disable Bottle instrumentation while leaving other integrations untouched.

CELERY

(2)
DD_CELERY_SERVICE
Type: string
Aliases:DD_CELERY_SERVICE_NAME
Sets the service name reported by the celery integration. When unset, the integration falls back to DD_CELERY_SERVICE_NAME and then to the default service name for Celery traces.
DD_TRACE_CELERY_ENABLED
Type: boolean
Default: true
Controls whether the celery integration is automatically patched when ddtrace instruments your application. When enabled (the default), Celery clients and workers are traced; set to false to disable Celery instrumentation while leaving other integrations untouched.

CHERRYPY

(1)
DD_CHERRYPY_SERVICE
Type: string
Default: cherrypy
Aliases:DD_CHERRYPY_SERVICE_NAME
Sets the service name reported by the cherrypy integration. When unset, traces fall back to the default service name "cherrypy".

CLAUDE_AGENT_SDK

(1)
DD_TRACE_CLAUDE_AGENT_SDK_ENABLED
Type: boolean
Default: true
Enables tracing of the Claude Code SDK

CONSUL

(2)
DD_CONSUL_SERVICE
Type: string
Aliases:DD_CONSUL_SERVICE_NAME
Sets the service name reported by the consul integration. When unset, the integration falls back to DD_CONSUL_SERVICE_NAME and then to the default service name "consul".
DD_TRACE_CONSUL_ENABLED
Type: boolean
Default: true
Controls whether the consul integration is automatically patched and traces Consul KV operations (get, put, delete). When disabled, no spans are produced for the python-consul client. Enabled by default.

COVERAGE

(2)
DD_COVERAGE_SERVICE
Type: string
Aliases:DD_COVERAGE_SERVICE_NAME
Sets the service name reported by the coverage integration. When unset, the integration falls back to DD_COVERAGE_SERVICE_NAME and then to the global service name.
DD_TRACE_COVERAGE_ENABLED
Type: boolean
Default: false
Enables the coverage integration, which patches Coverage.py to capture the coverage percentage when reports are generated. Disabled by default; set to true to enable.

CREWAI

(2)
DD_CREWAI_SERVICE
Type: string
Aliases:DD_CREWAI_SERVICE_NAME
Sets the service name reported for traces produced by the crewai integration, which instruments crew, task, agent, and tool executions in the CrewAI library. When unset, the integration falls back to DD_CREWAI_SERVICE_NAME and then to the global service name.
DD_TRACE_CREWAI_ENABLED
Type: boolean
Default: true
Controls whether the crewai integration is automatically patched and instrumented when crewai is imported. When enabled (the default), spans are produced for CrewAI agent, task, and crew executions. Set to false to disable instrumentation of the crewai library while leaving other integrations untouched.

DBAPI2

(1)
DD_DBAPI2_SERVICE
Type: string
Aliases:DD_DBAPI2_SERVICE_NAME
Sets the service name reported by the generic dbapi2 integration, which provides shared tracing for PEP 249-compliant database drivers (such as sqlite3, mysql, psycopg, and others that build on top of dbapi). When unset, traces fall back to the integration’s default service name.

DJANGO

(6)
DD_DJANGO_INCLUDE_USER_EMAIL
Type: boolean
Default: false
Controls whether the Django integration attaches the authenticated user’s email address (when available) as a tag on the root request span emitted for user events such as login, signup, and account-takeover detections by App and API Protection (AAP). When unset, the email is not collected.
DD_DJANGO_INCLUDE_USER_LOGIN
Type: boolean
Default: true
Controls whether the django integration includes the authenticated user’s login (when available) as a tag on the root request span emitted for App and API Protection user events (such as login success/failure). When unset, defaults to true.
DD_DJANGO_INCLUDE_USER_NAME
Type: boolean
Default: true
Controls whether the django integration adds the authenticated user’s name or id as a tag on the root request span. When enabled (the default), the user identifier is attached to Django request spans; when disabled, no user name/id tag is added.
DD_DJANGO_INCLUDE_USER_REALNAME
Type: boolean
Default: false
Controls whether the django integration includes the authenticated user’s real name (when available) as a tag on the root request span for ASM user events (login, signup, etc.). When unset, the real name is not attached to user-event tags.
DD_DJANGO_SERVICE
Type: string
Default: django
Aliases:DD_DJANGO_SERVICE_NAME
Sets the service name reported by the django integration for traces produced by your Django application. When unset, falls back to DD_DJANGO_SERVICE_NAME, then to the global service name (e.g. DD_SERVICE).
DD_TRACE_DJANGO_ENABLED
Type: boolean
Default: true
Controls whether the django integration is automatically patched when the tracer initializes. When set to false, Django request handling, ORM queries, templates, and cache operations are not instrumented and produce no spans. Defaults to enabled.

DOGPILE_CACHE

(2)
DD_DOGPILE_CACHE_SERVICE
Type: string
Aliases:DD_DOGPILE_CACHE_SERVICE_NAME
Sets the service name reported for traces produced by the dogpile_cache integration, which instruments dogpile.cache lookups. When unset, traces fall back to the default service name derived from dogpile.cache.
DD_TRACE_DOGPILE_CACHE_ENABLED
Type: boolean
Default: true
Controls whether the dogpile.cache integration is enabled. When enabled, cached lookups performed through dogpile.cache regions (including get_or_create and get_or_create_multi) are traced, with spans tagged by cache key, region, and backend.

DRAMATIQ

(2)
DD_DRAMATIQ_SERVICE
Type: string
Aliases:DD_DRAMATIQ_SERVICE_NAME
Sets the service name reported for traces produced by the dramatiq integration, which instruments background tasks defined with the @dramatiq.actor decorator. When unset, the integration falls back to DD_DRAMATIQ_SERVICE_NAME and then to the global service name.
DD_TRACE_DRAMATIQ_ENABLED
Type: boolean
Default: true
Controls whether the dramatiq integration is enabled. When enabled, dramatiq actors decorated with @dramatiq.actor are automatically traced, producing spans for Actor.send_with_options calls so background task executions appear in Datadog. Disable to opt out of dramatiq instrumentation.

ELASTICSEARCH

(2)
DD_ELASTICSEARCH_SERVICE
Type: string
Default: elasticsearch
Aliases:DD_ELASTICSEARCH_SERVICE_NAME
Sets the service name reported by default for Elasticsearch traces produced by the elasticsearch integration. When unset, traces fall back to the default service name "elasticsearch".
DD_TRACE_ELASTICSEARCH_ENABLED
Type: boolean
Default: true
Enables instrumentation for elasticsearch. When disabled, spans for elasticsearch operations are not created.

FALCON

(2)
DD_FALCON_SERVICE
Type: string
Aliases:DD_FALCON_SERVICE_NAME
Sets the service name reported by the falcon integration for traces produced by Falcon web applications. When unset, the integration falls back to DD_FALCON_SERVICE_NAME and then to the global service name.
DD_TRACE_FALCON_ENABLED
Type: boolean
Default: true
Controls whether the falcon integration is enabled. When set to true (the default), incoming requests handled by Falcon applications are automatically traced. Set to false to disable Falcon instrumentation entirely.

FASTAPI

(2)
DD_FASTAPI_SERVICE
Type: string
Default: fastapi
Aliases:DD_FASTAPI_SERVICE_NAME
Sets the service name reported by the fastapi integration. When unset, traces fall back to DD_FASTAPI_SERVICE_NAME, then to the global service name, and finally to the default "fastapi".
DD_TRACE_FASTAPI_ENABLED
Type: boolean
Default: true
Controls whether the fastapi integration is enabled when ddtrace auto-patches application libraries. When enabled, incoming FastAPI HTTP requests are traced as fastapi.request spans, including route, status, and request metadata. Disable to stop tracing FastAPI without removing the integration.

FLASK

(2)
DD_FLASK_SERVICE
Type: string
Default: flask
Aliases:DD_FLASK_SERVICE_NAME
Sets the service name reported by traces produced by the flask integration. When unset, the integration falls back to DD_FLASK_SERVICE_NAME and then to the global service name.
DD_TRACE_FLASK_ENABLED
Type: boolean
Default: true
Controls whether the flask integration is automatically patched when tracing is enabled. When set to false, Flask requests, views, and template rendering are not instrumented and no Flask spans are produced. When unset, the integration is enabled by default.

FLASK_CACHE

(1)
DD_FLASK_CACHE_SERVICE
Type: string
Aliases:DD_FLASK_CACHE_SERVICE_NAME
Sets the service name reported by the flask_cache integration for traces of Flask-Cache / Flask-Caching operations. When unset, the integration falls back to DD_FLASK_CACHE_SERVICE_NAME, then to the global service name, and finally to the default "flask-cache".

FUTURES

(2)
DD_FUTURES_SERVICE
Type: string
Aliases:DD_FUTURES_SERVICE_NAME
Sets the service name reported by the futures integration, which propagates trace context across concurrent.futures thread and process pool executors. When unset, the integration falls back to DD_FUTURES_SERVICE_NAME and then to the global service name.
DD_TRACE_FUTURES_ENABLED
Type: boolean
Default: true
Controls the futures integration, which propagates the active tracing context to tasks spawned via concurrent.futures.ThreadPoolExecutor so spans created inside worker threads continue the originating trace. Enabled by default; set to false to disable thread-context propagation for ThreadPoolExecutor tasks.

GENAI

(2)
DD_GENAI_SERVICE
Type: string
Aliases:DD_GENAI_SERVICE_NAME
Sets the service name reported by the genai integration. When unset, the integration falls back to DD_GENAI_SERVICE_NAME and then to the global service name.
DD_TRACE_GENAI_ENABLED
Type: boolean
Enables the Google GenAI plugin.

GEVENT

(2)
DD_GEVENT_SERVICE
Type: string
Aliases:DD_GEVENT_SERVICE_NAME
Sets the service name reported by the gevent integration. When unset, the integration falls back to DD_GEVENT_SERVICE_NAME and then to the global service name.
DD_TRACE_GEVENT_ENABLED
Type: boolean
Default: true
Controls whether the gevent integration is patched at startup, enabling automatic tracing of greenlet-based concurrency. Enabled by default; set to false to disable. If gevent is also listed in DD_PATCH_MODULES, that value takes precedence over this variable.

GOOGLE_ADK

(2)
DD_GOOGLE_ADK_SERVICE
Type: string
Aliases:DD_GOOGLE_ADK_SERVICE_NAME
Sets the service name reported for traces produced by the google_adk integration, which instruments the Google ADK Python SDK for agent requests. When unset, traces fall back to the global service name.
DD_TRACE_GOOGLE_ADK_ENABLED
Type: boolean
Default: true
Controls whether the google_adk integration is enabled, which instruments the Google ADK Python SDK to produce spans for Agent requests (tagged with model and provider). When unset, the integration is enabled by default.

GOOGLE_CLOUD_PUBSUB

(2)
DD_GOOGLE_CLOUD_PUBSUB_SERVICE
Type: string
Aliases:DD_GOOGLE_CLOUD_PUBSUB_SERVICE_NAME
Sets the service name reported by the google_cloud_pubsub integration, which traces Google Cloud Pub/Sub publishing and consuming via the google-cloud-pubsub library. When unset, the integration falls back to DD_GOOGLE_CLOUD_PUBSUB_SERVICE_NAME and then to the global service name.
DD_TRACE_GOOGLE_CLOUD_PUBSUB_ENABLED
Type: boolean
Default: true
Enables instrumentation for google cloud pubsub. When disabled, spans for google cloud pubsub operations are not created.

GOOGLE_GENAI

(2)
DD_GOOGLE_GENAI_SERVICE
Type: string
Aliases:DD_GOOGLE_GENAI_SERVICE_NAME
Sets the service name reported for traces produced by the google_genai integration (Google GenAI SDK). When unset, the integration falls back to DD_GOOGLE_GENAI_SERVICE_NAME and then to the global service name.
DD_TRACE_GOOGLE_GENAI_ENABLED
Type: boolean
Default: true
Enables instrumentation for google genai. When disabled, spans for google genai operations are not created.

GRAPHQL

(3)
DD_GRAPHQL_SERVICE
Type: string
Default: graphql
Aliases:DD_GRAPHQL_SERVICE_NAME
Sets the service name reported by the graphql integration. When unset, the integration falls back to DD_GRAPHQL_SERVICE_NAME and then to the global service name.
DD_TRACE_GRAPHQL_ENABLED
Type: boolean
Default: true
Enables instrumentation for graphql. When disabled, spans for graphql operations are not created.
DD_TRACE_GRAPHQL_ERROR_EXTENSIONS
Type: array
Comma-separated list of GraphQL error extension keys to capture as span tags. When unset, no extensions are captured.

GRAPHQL_RESOLVERS

(1)
DD_TRACE_GRAPHQL_RESOLVERS_ENABLED
Type: boolean
Default: false
When enabled, the graphql integration emits a graphql.resolve span for every resolved GraphQL field, in addition to the standard query/parse/validate/execute spans. Disabled by default because complex GraphQL queries can produce very large traces with one span per field.

GRPC

(1)
DD_TRACE_GRPC_ENABLED
Type: boolean
Default: true
Enables instrumentation for grpc. When disabled, spans for grpc operations are not created.

GRPC_AIO_CLIENT

(1)
DD_GRPC_AIO_CLIENT_SERVICE
Type: string
Aliases:DD_GRPC_AIO_CLIENT_SERVICE_NAME
Sets the service name reported for traces produced by the gRPC asyncio client integration (grpc_aio_client). When unset, traces fall back to DD_GRPC_AIO_CLIENT_SERVICE_NAME and then to the default service name "grpc-aio-client".

GRPC_AIO_SERVER

(1)
DD_GRPC_AIO_SERVER_SERVICE
Type: string
Aliases:DD_GRPC_AIO_SERVER_SERVICE_NAME
Sets the service name reported by the grpc_aio_server integration for spans created by asyncio gRPC servers. When unset, traces fall back to the default service name "grpc-aio-server".

GRPC_CLIENT

(2)
DD_GRPC_CLIENT_SERVICE
Type: string
Aliases:DD_GRPC_CLIENT_SERVICE_NAME
Sets the service name reported by the grpc_client integration for outgoing gRPC client calls. When unset, falls back to DD_GRPC_CLIENT_SERVICE_NAME and then to the default "grpc-client".
DD_TRACE_GRPC_CLIENT_ENABLED
Type: boolean
Default: true
Aliases:DD_TRACE_INTEGRATION_GRPC_CLIENT_ENABLED, DD_INTEGRATION_GRPC_CLIENT_ENABLED
Enables gRPC client tracing (creates spans for outgoing RPCs, injects propagation metadata, and traces client call/stream/message callbacks)

GRPC_SERVER

(2)
DD_GRPC_SERVER_SERVICE
Type: string
Aliases:DD_GRPC_SERVER_SERVICE_NAME
Sets the service name reported by default for gRPC server-side traces produced by the grpc integration. When unset, traces fall back to the global service name (DD_SERVICE), and otherwise to the default "grpc-server".
DD_TRACE_GRPC_SERVER_ENABLED
Type: boolean
Default: true
Aliases:DD_TRACE_INTEGRATION_GRPC_SERVER_ENABLED, DD_INTEGRATION_GRPC_SERVER_ENABLED
Enables gRPC server tracing (installs a tracing ServerInterceptor to create spans for inbound RPCs and optionally records handler code origin)

HTTPLIB

(2)
DD_HTTPLIB_SERVICE
Type: string
Aliases:DD_HTTPLIB_SERVICE_NAME
Sets the service name reported by the httplib integration, which traces outbound HTTP requests made via Python’s standard http.client (and urllib) module. When unset, the integration falls back to DD_HTTPLIB_SERVICE_NAME and then to the global service name.
DD_TRACE_HTTPLIB_ENABLED
Type: boolean
Default: false
Enables tracing of HTTP requests made through the Python standard library http.client (formerly httplib) module. The httplib integration is disabled by default; setting this to true patches http.client so outbound HTTP calls produce spans.

HTTPX

(2)
DD_HTTPX_SERVICE
Type: string
Aliases:DD_HTTPX_SERVICE_NAME
Sets the service name reported for outbound HTTP requests traced by the httpx integration. When unset, spans inherit the service name from their parent span instead of defining their own. Falls back to DD_HTTPX_SERVICE_NAME if neither is set. Note that DD_HTTPX_SPLIT_BY_DOMAIN, when enabled, takes precedence over this value.
DD_TRACE_HTTPX_ENABLED
Type: boolean
Default: true
Controls whether the httpx integration is enabled, automatically tracing outbound HTTP requests made with the httpx library’s sync and async clients. When unset, the integration is enabled by default.

JINJA2

(2)
DD_JINJA2_SERVICE
Type: string
Aliases:DD_JINJA2_SERVICE_NAME
Sets the service name reported by the jinja2 integration for template loading, compilation, and rendering spans. When unset, the service name is inherited from the parent span; if there is no parent span and no service is configured, the Agent drops the traces.
DD_TRACE_JINJA2_ENABLED
Type: boolean
Default: true
Controls whether the jinja2 integration is enabled, which traces template rendering, compilation, and loading operations performed by the Jinja2 engine. When enabled (the default), spans are emitted for jinja2 template execution. Set to false to disable instrumentation of Jinja2.

KAFKA

(3)
DD_KAFKA_PROPAGATION_ENABLED
Type: boolean
Whether to propagate trace context via Kafka
DD_KAFKA_SERVICE
Type: string
Default: kafka
Aliases:DD_KAFKA_SERVICE_NAME
Sets the service name reported by default for Kafka spans produced by the kafka integration (which instruments confluent-kafka). When unset, traces fall back to the default service name "kafka".
DD_TRACE_KAFKA_ENABLED
Type: boolean
Default: true
Aliases:DD_INTEGRATION_KAFKA_ENABLED, DD_TRACE_INTEGRATION_KAFKA_ENABLED
Enables tracing for the Kafka integration.

KOMBU

(2)
DD_KOMBU_SERVICE
Type: string
Default: kombu
Aliases:DD_KOMBU_SERVICE_NAME
Sets the service name reported by default for spans produced by the kombu integration. When unset, the integration falls back to DD_KOMBU_SERVICE_NAME and then to the default service name "kombu".
DD_TRACE_KOMBU_ENABLED
Type: boolean
Default: false
Controls whether the kombu integration is enabled. When enabled, the tracer instruments the kombu messaging library to produce spans for message publish and consume operations. Disabled by default; set to true to opt in.

LANGCHAIN

(2)
DD_LANGCHAIN_SERVICE
Type: string
Aliases:DD_LANGCHAIN_SERVICE_NAME
Sets the service name reported by default for traces produced by the langchain integration. When unset, the integration falls back to DD_LANGCHAIN_SERVICE_NAME and then to the global service name.
DD_TRACE_LANGCHAIN_ENABLED
Type: boolean
Default: true
Enables instrumentation for langchain. When disabled, spans for langchain operations are not created.

LANGGRAPH

(2)
DD_LANGGRAPH_SERVICE
Type: string
Aliases:DD_LANGGRAPH_SERVICE_NAME
Sets the service name reported by default for traces produced by the langgraph integration, which instruments the LangGraph Python library to emit traces for graph and node invocations. When unset, traces fall back to DD_LANGGRAPH_SERVICE_NAME and then to the global service name.
DD_TRACE_LANGGRAPH_ENABLED
Type: boolean
Default: true
To enable the LangGraph Integration.

LITELLM

(2)
DD_LITELLM_SERVICE
Type: string
Aliases:DD_LITELLM_SERVICE_NAME
Sets the service name reported by the litellm integration. When unset, the integration falls back to DD_LITELLM_SERVICE_NAME and then to the global service name.
DD_TRACE_LITELLM_ENABLED
Type: boolean
Default: true
Controls whether the litellm integration is enabled, which instruments the LiteLLM Python SDK and proxy server to produce traces for LLM requests. When enabled (the default), LiteLLM calls are automatically traced; set to false to disable instrumentation for this integration.

LLAMA_INDEX

(1)
DD_LLAMA_INDEX_SERVICE
Type: string
Aliases:DD_LLAMA_INDEX_SERVICE_NAME
Sets the service name reported by the llama_index integration. When unset, traces fall back to the global service name configured for the application.

LOGBOOK

(2)
DD_LOGBOOK_SERVICE
Type: string
Aliases:DD_LOGBOOK_SERVICE_NAME
Sets the service name reported by the logbook integration, which injects trace correlation fields into log records produced via logbook. When unset, the integration falls back to DD_LOGBOOK_SERVICE_NAME and then to the global service name.
DD_TRACE_LOGBOOK_ENABLED
Type: boolean
Default: true
Controls whether the logbook integration is automatically patched when ddtrace is loaded. When enabled, ddtrace patches logbook.base.RecordDispatcher.process_record so that trace correlation fields (dd.trace_id, dd.span_id, dd.env, dd.service, dd.version) are injected into log records, enabling APM/log correlation when a structured (e.g. JSON) format is used. Set to false to skip patching the logbook library.

LOGGING

(1)
DD_TRACE_LOGGING_ENABLED
Type: boolean
Default: true
Controls whether the logging integration is automatically patched when ddtrace auto-instruments your application. When enabled, log records are enriched with trace correlation fields (such as dd.trace_id and dd.span_id) so logs can be linked to traces in Datadog. When disabled, the logging integration is skipped during auto-instrumentation. Defaults to true.

LOGURU

(2)
DD_LOGURU_SERVICE
Type: string
Aliases:DD_LOGURU_SERVICE_NAME
Sets the service name reported by the loguru logging integration. When unset, the integration falls back to DD_LOGURU_SERVICE_NAME and then to the global service name.
DD_TRACE_LOGURU_ENABLED
Type: boolean
Default: true
Controls whether the loguru integration is automatically patched when ddtrace is loaded. When enabled, ddtrace configures a loguru patcher that injects trace correlation fields (dd.trace_id, dd.span_id, dd.env, dd.service, dd.version) into every log record, enabling APM/log correlation when a structured (e.g. JSON) format is used. Set to false to skip patching the loguru library.

MAKO

(2)
DD_MAKO_SERVICE
Type: string
Aliases:DD_MAKO_SERVICE_NAME
Sets the service name reported by the mako integration for spans produced when rendering Mako templates. When unset, traces fall back to DD_MAKO_SERVICE_NAME, then to the global service name, and finally to the default "mako".
DD_TRACE_MAKO_ENABLED
Type: boolean
Default: true
Controls whether the mako integration is enabled. When enabled, traces are emitted for Mako template rendering operations (Template.render, render_unicode, and render_context), including the template name as a tag. Disable to stop instrumenting Mako templates.

MARIADB

(2)
DD_MARIADB_SERVICE
Type: string
Default: mariadb
Aliases:DD_MARIADB_SERVICE_NAME
Sets the service name reported for MariaDB traces produced by the mariadb integration. When unset, traces fall back to the default service name "mariadb".
DD_TRACE_MARIADB_ENABLED
Type: boolean
Default: true
Enables instrumentation for mariadb. When disabled, spans for mariadb operations are not created.

MCP

(2)
DD_MCP_SERVICE
Type: string
Aliases:DD_MCP_SERVICE_NAME
Sets the service name reported by the mcp integration, which instruments the MCP (Model Context Protocol) Python library to emit traces for client tool calls and server tool executions. When unset, traces fall back to the global service name.
DD_TRACE_MCP_ENABLED
Type: boolean
Default: true
Controls whether the mcp integration is automatically patched and traces are produced for Model Context Protocol clients and servers. When unset, the integration is enabled by default.

MEMCACHED_COMMAND

(1)
DD_TRACE_MEMCACHED_COMMAND_ENABLED
Type: boolean
Default: false
Enable memcached command tagging if DD_TRACE_MEMCACHED_COMMAND_ENABLED is enabled

MLFLOW

(1)
DD_MLFLOW_SERVICE
Type: string
Aliases:DD_MLFLOW_SERVICE_NAME
Sets the service name reported by the mlflow integration for spans tracking MLflow runs and steps. When unset, the integration falls back to DD_MLFLOW_SERVICE_NAME and then to the global service name.

MOLTEN

(2)
DD_MOLTEN_SERVICE
Type: string
Default: molten
Aliases:DD_MOLTEN_SERVICE_NAME
Sets the service name reported by the molten integration for traces produced by your Molten app. When unset, the integration falls back to DD_SERVICE and then to the default service name "molten".
DD_TRACE_MOLTEN_ENABLED
Type: boolean
Default: true
Controls whether the molten integration is automatically patched at startup, producing traces for incoming HTTP requests handled by molten apps. When unset, the integration is enabled by default.

MYSQL

(2)
DD_MYSQL_SERVICE
Type: string
Default: mysql
Aliases:DD_MYSQL_SERVICE_NAME
Sets the service name reported by default for MySQL traces produced by the mysql integration. When unset, traces fall back to the default service name "mysql".
DD_TRACE_MYSQL_ENABLED
Type: boolean
Default: true
Enables instrumentation for mysql. When disabled, spans for mysql operations are not created.

MYSQLDB

(2)
DD_MYSQLDB_SERVICE
Type: string
Default: mysql
Aliases:DD_MYSQLDB_SERVICE_NAME
Sets the service name reported by default for spans produced by the mysqldb integration. When unset, traces fall back to the default service name "mysql".
DD_TRACE_MYSQLDB_ENABLED
Type: boolean
Default: true
Controls whether the mysqldb integration is automatically patched to trace queries made through the mysqlclient (MySQLdb) library. When unset, the integration is enabled by default. Set to false to disable instrumentation of MySQLdb connections and cursors.

OPENAI

(2)
DD_OPENAI_SERVICE
Type: string
Aliases:DD_OPENAI_SERVICE_NAME
The service name reported by default for OpenAI requests.
DD_TRACE_OPENAI_ENABLED
Type: boolean
Default: true
Enables instrumentation for openai. When disabled, spans for openai operations are not created.

OPENAI_AGENTS

(2)
DD_OPENAI_AGENTS_SERVICE
Type: string
Aliases:DD_OPENAI_AGENTS_SERVICE_NAME
Sets the service name reported by default for traces produced by the openai_agents integration, which instruments the openai-agents Python library for agent workflows. When unset, the integration falls back to DD_OPENAI_AGENTS_SERVICE_NAME and then to the global service name.
DD_TRACE_OPENAI_AGENTS_ENABLED
Type: boolean
Default: true
Enables tracing for OpenAI Agents.

PROPAGATION_HTTP_BAGGAGE

(1)
DD_TRACE_PROPAGATION_HTTP_BAGGAGE_ENABLED
Type: boolean
Default: false
When enabled, baggage items attached to a span context are propagated across HTTP requests using ot-baggage-<key> headers. On injection, each baggage entry is written as a header; on extraction, incoming ot-baggage-* headers are attached to the resulting context. This is independent of the W3C baggage propagation style and is disabled by default.

PROTOBUF

(2)
DD_PROTOBUF_SERVICE
Type: string
Aliases:DD_PROTOBUF_SERVICE_NAME
Sets the service name reported by the protobuf integration. When unset, the integration falls back to DD_PROTOBUF_SERVICE_NAME and then to the global service name.
DD_TRACE_PROTOBUF_ENABLED
Type: boolean
Default: false
Aliases:DD_TRACE_INTEGRATION_PROTOBUF_ENABLED, DD_INTEGRATION_PROTOBUF_ENABLED
Enables protobuf schema extraction (attaches protobuf message descriptors to the active span during protobuf serialization/deserialization and records parse/write errors)

PSYCOPG

(1)
DD_TRACE_PSYCOPG_ENABLED
Type: boolean
Default: true
Controls whether the psycopg integration is automatically patched on startup, instrumenting psycopg (v3) and psycopg2 PostgreSQL clients to produce database spans. When unset, the integration is enabled by default. Set to a falsy value to disable patching of psycopg connections, cursors, and queries.

PYDANTIC_AI

(2)
DD_PYDANTIC_AI_SERVICE
Type: string
Aliases:DD_PYDANTIC_AI_SERVICE_NAME
Sets the service name reported for traces produced by the pydantic_ai integration, which instruments the PydanticAI agent framework. When unset, traces fall back to the global service name.
DD_TRACE_PYDANTIC_AI_ENABLED
Type: boolean
Default: true
Controls whether the pydantic_ai integration is patched and produces traces for Pydantic AI agent runs, streams, and tool calls. When unset, the integration is enabled by default; set to a falsy value to disable instrumentation of pydantic_ai.

PYLIBMC

(2)
DD_PYLIBMC_SERVICE
Type: string
Aliases:DD_PYLIBMC_SERVICE_NAME
Sets the service name reported for traces produced by the pylibmc integration, which instruments memcached clients. When unset, traces fall back to the default service name "memcached".
DD_TRACE_PYLIBMC_ENABLED
Type: boolean
Default: true
Controls whether the pylibmc integration is enabled, which instruments the pylibmc Memcached client to produce spans for cache operations such as get, set, and delete. When unset, the integration is enabled by default.

PYMEMCACHE

(2)
DD_PYMEMCACHE_SERVICE
Type: string
Aliases:DD_PYMEMCACHE_SERVICE_NAME
Sets the service name reported by default for memcached traces produced by the pymemcache integration. When unset, traces fall back to the default service name "pymemcache".
DD_TRACE_PYMEMCACHE_ENABLED
Type: boolean
Default: true
Controls whether the pymemcache integration is enabled, instrumenting pymemcache Client and HashClient calls to report memcached queries as spans. When unset, the integration is enabled by default.

PYMONGO

(2)
DD_PYMONGO_SERVICE
Type: string
Default: pymongo
Aliases:DD_PYMONGO_SERVICE_NAME
Sets the service name reported by default for spans produced by the pymongo integration. When unset, traces fall back to the default service name "pymongo".
DD_TRACE_PYMONGO_ENABLED
Type: boolean
Default: true
Controls whether the pymongo integration is automatically enabled when ddtrace patches supported libraries. When enabled (the default), MongoDB calls made through pymongo.MongoClient are traced as spans reporting database queries. Set to false to disable pymongo instrumentation while keeping other integrations active.

PYMYSQL

(2)
DD_PYMYSQL_SERVICE
Type: string
Default: pymysql
Aliases:DD_PYMYSQL_SERVICE_NAME
Sets the service name reported by default for MySQL traces produced by the pymysql integration. When unset, traces fall back to the default service name "mysql".
DD_TRACE_PYMYSQL_ENABLED
Type: boolean
Default: true
Controls whether the pymysql integration is enabled. When enabled (the default), ddtrace automatically patches pymysql to produce spans for MySQL queries executed through the client. Set to false to disable instrumentation of pymysql while keeping other integrations active.

PYNAMODB

(2)
DD_PYNAMODB_SERVICE
Type: string
Default: pynamodb
Aliases:DD_PYNAMODB_SERVICE_NAME
Sets the service name reported by default for traces produced by the pynamodb integration. When unset, traces fall back to the default service name "pynamodb".
DD_TRACE_PYNAMODB_ENABLED
Type: boolean
Default: true
Controls whether the pynamodb integration is auto-instrumented to trace DynamoDB calls made through PynamoDB. When enabled (the default), database operations issued via PynamoDB connections are captured as spans. Set to false to disable tracing for this integration.

PYODBC

(2)
DD_PYODBC_SERVICE
Type: string
Default: pyodbc
Aliases:DD_PYODBC_SERVICE_NAME
Sets the service name reported by default for spans produced by the pyodbc integration. When unset, traces fall back to the default service name "pyodbc".
DD_TRACE_PYODBC_ENABLED
Type: boolean
Default: true
Controls whether the pyodbc integration is enabled, which traces queries made through the pyodbc database driver. When enabled (the default), pyodbc connections and cursor operations are automatically instrumented to produce database spans. Set to false to disable tracing for pyodbc.

PYRAMID

(2)
DD_PYRAMID_SERVICE
Type: string
Default: pyramid
Aliases:DD_PYRAMID_SERVICE_NAME
Sets the service name reported by the pyramid integration for traces produced by Pyramid web applications. When unset, the integration falls back to DD_PYRAMID_SERVICE_NAME, then to the global service name, and finally to the default "pyramid".
DD_TRACE_PYRAMID_ENABLED
Type: boolean
Default: true
Controls whether the pyramid integration is auto-patched when tracing is initialized. When enabled (the default), incoming Pyramid requests and template renders are traced automatically. Set to a falsy value to disable instrumentation of the Pyramid web framework.

PYTEST

(2)
DD_PYTEST_SERVICE
Type: string
Default: pytest
Aliases:DD_PYTEST_SERVICE_NAME
Sets the service name reported by the pytest integration for test traces. When unset, the integration falls back to the name of the repository being tested, or to "pytest" if the repository name cannot be determined, before deferring to the global service name.
DD_PYTEST_USE_NEW_PLUGIN_BETA
Type: string
Deprecated opt-in flag that previously enabled the rewritten pytest integration plugin. The new plugin is now the default and no configuration is required to use it. When this variable is set to any non-empty value, the integration emits a deprecation warning at pytest configuration time. Scheduled for removal in version 3.0.0.

PYTEST_BDD

(1)
DD_PYTEST_BDD_SERVICE
Type: string
Default: pytest_bdd
Aliases:DD_PYTEST_BDD_SERVICE_NAME
Sets the service name reported by the pytest_bdd integration for spans produced from pytest-bdd scenarios and steps. When unset, the integration falls back to DD_PYTEST_BDD_SERVICE_NAME, then to the global service name, and finally to the default "pytest_bdd".

RAY

(5)
DD_RAY_SERVICE
Type: string
Aliases:DD_RAY_SERVICE_NAME
Sets the service name reported by the ray integration for spans produced by Ray jobs and workers. When unset, falls back to DD_RAY_SERVICE_NAME, then to a job name derived from Ray metadata or the global service name, and finally to a built-in default job name.
DD_TRACE_RAY_ARGS_KWARGS
Type: boolean
Default: false
When enabled, the ray integration captures the positional arguments and keyword arguments passed to Ray tasks and actor methods as span tags. Disabled by default to avoid recording potentially large or sensitive payloads.
DD_TRACE_RAY_CORE_API
Type: boolean
Default: false
Enables tracing of Ray’s core API functions (ray.get, ray.put, ray.wait) by the ray integration. When disabled, these calls execute without producing spans, while higher-level Ray instrumentation (jobs, tasks, actor methods) is unaffected. Disabled by default.
DD_TRACE_RAY_ENABLED
Type: boolean
Default: false
Enables tracing for the ray integration. When set to true, ddtrace patches Ray to emit spans for jobs, tasks, and actor method calls. Disabled by default; the integration must be explicitly opted in via this variable (or by calling patch(ray=True)).
DD_TRACE_RAY_IGNORED_ACTORS
Type: json
Default: {}
JSON object mapping Ray actor class names to a list of method names that should be excluded from instrumentation by the ray integration. Use the value "*" instead of a list to exclude every method on that actor class. For example, {"ActorA": ["method1"], "ActorB": "*"} skips ActorA.method1 and all methods on ActorB. Matching is by class name only (module is ignored). When unset, no actors or methods are excluded.

RAY_SUBMISSION_SPANS

(1)
DD_TRACE_RAY_SUBMISSION_SPANS_ENABLED
Type: boolean
Default: false
When enabled, the ray integration emits spans for task.submit and actor_method.submit calls in addition to execution spans. Disabled by default to reduce span volume in high-throughput Ray workloads. Enable it for visibility into queuing/submission latency, fan-out patterns, or when work is submitted but delayed before execution.

REDIS

(2)
DD_REDIS_SERVICE
Type: string
Default: redis
Aliases:DD_REDIS_SERVICE_NAME
Sets the service name reported by default for Redis traces produced by the redis integration. When unset, traces fall back to the default service name "redis".
DD_TRACE_REDIS_ENABLED
Type: boolean
Default: true
Aliases:DD_TRACE_INTEGRATION_REDIS_ENABLED, DD_INTEGRATION_REDIS_ENABLED
Enables instrumentation for redis. When disabled, spans for redis operations are not created.

REDISCLUSTER

(2)
DD_REDISCLUSTER_SERVICE
Type: string
Default: rediscluster
Aliases:DD_REDISCLUSTER_SERVICE_NAME
Sets the service name reported by default for traces produced by the rediscluster integration. When unset, traces fall back to the default service name "rediscluster".
DD_TRACE_REDISCLUSTER_ENABLED
Type: boolean
Default: true
Controls whether the rediscluster integration is automatically patched to trace Redis Cluster queries made through the redis-py-cluster package. When enabled, calls on RedisCluster, StrictRedisCluster, and their pipeline classes are instrumented and reported under the rediscluster service. When unset, the integration is enabled by default.

REQUESTS

(2)
DD_REQUESTS_SERVICE
Type: string
Default: requests
Aliases:DD_REQUESTS_SERVICE_NAME
Sets the service name reported by default for HTTP traces produced by the requests integration. When unset, traces fall back to the default service name "requests". This value is overridden when the split_by_domain setting is enabled, in which case the request’s domain is used as the service name.
DD_TRACE_REQUESTS_ENABLED
Type: boolean
Default: true
Controls whether the requests integration is automatically patched and traces HTTP client calls made via the requests library. When unset, the integration is enabled by default. Set to false to disable tracing for requests while leaving other integrations untouched.

RQ

(2)
DD_RQ_SERVICE
Type: string
Default: rq
Aliases:DD_RQ_SERVICE_NAME
Sets the service name reported by default for RQ spans produced by the rq integration on the enqueuer side. When unset, traces fall back to DD_SERVICE and finally to the default service name "rq".
DD_TRACE_RQ_ENABLED
Type: boolean
Default: true
Controls whether the rq integration produces traces for RQ (Redis Queue) job enqueues, fetches, and worker job execution. When set to false, the integration is patched but emits no spans. Defaults to enabled when the rq library is present.

RQ_WORKER

(1)
DD_RQ_WORKER_SERVICE
Type: string
Default: rq-worker
Aliases:DD_RQ_WORKER_SERVICE_NAME
Sets the service name reported by default for traces produced by RQ workers via the rq integration. When unset, traces fall back to the default service name "rq-worker".

SAFE_INSTRUMENTATION

(1)
DD_TRACE_SAFE_INSTRUMENTATION_ENABLED
Type: boolean
Default: false
When enabled, ddtrace checks whether each installed package’s version falls within the supported range of its corresponding integration before patching. Packages outside the supported range are left unpatched, which helps avoid application crashes caused by instrumenting incompatible library versions. When unset, all available integrations are patched without a version compatibility check.

SANIC

(2)
DD_SANIC_SERVICE
Type: string
Default: sanic
Aliases:DD_SANIC_SERVICE_NAME
Sets the service name reported by the sanic integration. When unset, the integration falls back to DD_SANIC_SERVICE_NAME and then to the global service name.
DD_TRACE_SANIC_ENABLED
Type: boolean
Default: true
Controls whether the sanic integration is enabled. When enabled, incoming Sanic HTTP requests are automatically traced, producing server spans with request method, URL, status code, and headers. Set to false to disable Sanic instrumentation while leaving other integrations untouched.

SELENIUM

(1)
DD_SELENIUM_SERVICE
Type: string
Aliases:DD_SELENIUM_SERVICE_NAME
Sets the service name reported by the selenium integration. When unset, the integration falls back to DD_SELENIUM_SERVICE_NAME and then to the global service name.

SNOWFLAKE

(2)
DD_SNOWFLAKE_SERVICE
Type: string
Default: snowflake
Aliases:DD_SNOWFLAKE_SERVICE_NAME
Sets the service name reported by default for Snowflake traces produced by the snowflake integration. When unset, traces fall back to the default service name "snowflake".
DD_TRACE_SNOWFLAKE_ENABLED
Type: boolean
Default: false
Controls whether the snowflake integration is enabled, which instruments the snowflake-connector-python library to trace Snowflake queries. The integration is in beta and is not enabled automatically by ddtrace-run or import ddtrace.auto; set this to true to opt in. Equivalent to setting DD_PATCH_MODULES=snowflake:true.

SQLALCHEMY

(2)
DD_SQLALCHEMY_SERVICE
Type: string
Aliases:DD_SQLALCHEMY_SERVICE_NAME
Sets the service name reported by the sqlalchemy integration. When unset, traces fall back to DD_SQLALCHEMY_SERVICE_NAME and then to the parent service or database engine name detected by the integration.
DD_TRACE_SQLALCHEMY_ENABLED
Type: boolean
Default: false
Controls whether the sqlalchemy integration is enabled. When enabled, SQLAlchemy engine operations are traced. Disabled by default in favor of tracing the underlying database client (e.g. psycopg, mysql, sqlite3) directly to avoid duplicate spans.

SQLITE

(1)
DD_SQLITE_SERVICE
Type: string
Default: sqlite
Aliases:DD_SQLITE_SERVICE_NAME
Sets the service name reported by default for SQLite traces produced by the sqlite integration. When unset, traces fall back to the default service name "sqlite".

SQLITE3

(2)
DD_SQLITE3_SERVICE
Type: string
Aliases:DD_SQLITE3_SERVICE_NAME
Sets the service name reported by default for traces produced by the sqlite3 integration. When unset, traces fall back to the default service name "sqlite".
DD_TRACE_SQLITE3_ENABLED
Type: boolean
Default: true
Enables instrumentation for sqlite3. When disabled, spans for sqlite3 operations are not created.

STARLETTE

(2)
DD_STARLETTE_SERVICE
Type: string
Default: starlette
Aliases:DD_STARLETTE_SERVICE_NAME
Sets the service name reported by default for traces produced by the starlette integration. When unset, traces fall back to the default service name "starlette".
DD_TRACE_STARLETTE_ENABLED
Type: boolean
Default: true
Controls whether the starlette integration is enabled. When enabled, incoming requests handled by Starlette applications are traced, including routing, middleware, and background tasks. Set to false to disable Starlette tracing while leaving other integrations unaffected.

STRUCTLOG

(2)
DD_STRUCTLOG_SERVICE
Type: string
Aliases:DD_STRUCTLOG_SERVICE_NAME
Sets the service name reported by the structlog integration, which injects tracing context into structlog-rendered log records. When unset, the integration falls back to DD_STRUCTLOG_SERVICE_NAME and then to the global service name.
DD_TRACE_STRUCTLOG_ENABLED
Type: boolean
Default: true
Controls whether the structlog integration is patched on patch_all(). When enabled, ddtrace injects trace context (trace ID, span ID, service, env, version) into structlog log records by prepending a Datadog processor to the configured processor chain, allowing logs to be correlated with APM traces. Set to false to disable patching of structlog even when patch_all() is called.

SUBPROCESS

(2)
DD_SUBPROCESS_SERVICE
Type: string
Aliases:DD_SUBPROCESS_SERVICE_NAME
Sets the service name reported by the subprocess integration, which traces commands executed via Python’s subprocess module. When unset, the integration falls back to DD_SUBPROCESS_SERVICE_NAME and then to the global service name.
DD_TRACE_SUBPROCESS_ENABLED
Type: boolean
Default: true
Controls whether the subprocess integration is enabled. When enabled, subprocess.Popen and related os functions (os.system, os.fork, os.spawn*) are instrumented so that command executions can be monitored by Application Security features such as AAP. Disable to skip patching of these functions entirely.

TORNADO

(2)
DD_TORNADO_SERVICE
Type: string
Aliases:DD_TORNADO_SERVICE_NAME
Sets the service name reported by the tornado integration. When unset, the integration falls back to DD_TORNADO_SERVICE_NAME and then to the global service name.
DD_TRACE_TORNADO_ENABLED
Type: boolean
Default: false
Controls whether the tornado integration is enabled, which instruments the Tornado web framework to produce traces for incoming requests, handlers, and template rendering. When unset, the integration is disabled by default and Tornado applications are not auto-instrumented.

UNITTEST

(2)
DD_TRACE_UNITTEST_ENABLED
Type: boolean
Default: true
Controls whether the unittest integration is enabled, which traces test executions and reports them to Datadog Test Visibility. When enabled (the default), tests run via Python’s unittest framework are automatically instrumented when ddtrace-run or import ddtrace.auto is used. Set to false to disable instrumentation of unittest tests.
DD_UNITTEST_SERVICE
Type: string
Default: unittest
Aliases:DD_UNITTEST_SERVICE_NAME
Sets the service name reported by the unittest integration. When unset, the integration falls back to DD_UNITTEST_SERVICE_NAME and then to the global service name.

URLLIB3

(2)
DD_TRACE_URLLIB3_ENABLED
Type: boolean
Default: false
Controls whether the urllib3 integration is enabled, instrumenting outgoing HTTP requests made via urllib3 with optional distributed tracing across services. The integration is disabled by default; set this to true to opt in. Equivalent to including urllib3 in DD_PATCH_MODULES.
DD_URLLIB3_SERVICE
Type: string
Default: urllib3
Aliases:DD_URLLIB3_SERVICE_NAME
Sets the service name reported by default for traces produced by the urllib3 integration. When unset, traces fall back to the default service name "urllib3".

VALKEY

(2)
DD_TRACE_VALKEY_ENABLED
Type: boolean
Default: true
Aliases:DD_INTEGRATION_VALKEY_ENABLED, DD_TRACE_INTEGRATION_VALKEY_ENABLED
Enables Valkey instrumentation
DD_VALKEY_SERVICE
Type: string
Default: valkey
Aliases:DD_VALKEY_SERVICE_NAME
Sets the service name reported by the valkey integration. When unset, the integration falls back to DD_VALKEY_SERVICE_NAME and then to the default service name "valkey".

VERTEXAI

(2)
DD_TRACE_VERTEXAI_ENABLED
Type: boolean
Default: true
Controls whether the vertexai integration is enabled, which instruments the Vertex Generative AI SDK for Python to trace requests made to Google models. When enabled (the default), calls made through the Vertex AI SDK produce spans tagged with the model and provider. Set to false to disable tracing of Vertex AI requests.
DD_VERTEXAI_SERVICE
Type: string
Aliases:DD_VERTEXAI_SERVICE_NAME
Sets the service name reported by the vertexai integration for traces produced when instrumenting the Vertex AI Generative AI SDK. When unset, the integration falls back to the global service name.

VERTICA

(2)
DD_TRACE_VERTICA_ENABLED
Type: boolean
Default: true
Controls whether the vertica integration is enabled, which traces queries made using the vertica-python library. When enabled (the default), vertica-python is automatically patched on import so that database queries produce spans. Set to false to disable tracing for this integration. Note: the Vertica integration is deprecated and will be removed in a future version.
DD_VERTICA_SERVICE
Type: string
Default: vertica
Aliases:DD_VERTICA_SERVICE_NAME
Sets the service name reported by the vertica integration, which traces queries made through vertica-python. When unset, traces fall back to the default service name "vertica".

VLLM

(2)
DD_TRACE_VLLM_ENABLED
Type: boolean
Default: true
Controls whether the vllm integration is enabled. When enabled, requests through the vLLM V1 engine are traced, capturing model name, latency metrics (TTFT, queue, prefill, decode, inference), and token usage. When disabled, no vLLM spans are produced. Requires vLLM V1 (VLLM_USE_V1=1) and vLLM >= 0.10.2.
DD_VLLM_SERVICE
Type: string
Aliases:DD_VLLM_SERVICE_NAME
Sets the service name reported by default for traces produced by the vllm integration. When unset, traces fall back to the default service name "vllm".

WEBSOCKET_MESSAGES

(2)
DD_TRACE_WEBSOCKET_MESSAGES_ENABLED
Type: boolean
Default: true
Enables tracing sent and received websocket messages (text and binary) and connection close events.
DD_TRACE_WEBSOCKET_MESSAGES_SEPARATE_TRACES
Type: boolean
Default: true
By default, each received message generates a new trace. The handshake is linked to it as a span link. Setting this parameter to false causes all the spans captured during the session to be in the same trace.

WSGI

(1)
DD_WSGI_SERVICE
Type: string
Default: wsgi
Aliases:DD_WSGI_SERVICE_NAME
Sets the service name reported by the wsgi integration for traces produced by WSGI-based applications. When unset, the integration falls back to DD_WSGI_SERVICE_NAME, then to the global service name, and finally to the default service name "wsgi".

YAAREDIS

(2)
DD_TRACE_YAAREDIS_ENABLED
Type: boolean
Default: true
Controls whether the yaaredis integration is enabled. When enabled, calls made through the yaaredis client are automatically traced as Redis spans. Disable to skip patching the yaaredis library and stop emitting spans for its commands and pipelines. Note: this integration is deprecated and scheduled for removal.
DD_YAAREDIS_SERVICE
Type: string
Default: redis
Aliases:DD_YAAREDIS_SERVICE_NAME
Sets the service name reported by default for traces produced by the yaaredis integration. When unset, traces fall back to the default service name "redis".

Database Monitoring

(2)

Database Monitoring (DBM): SQL comment propagation modes and query identifier hashing for correlating database performance with application traces.

DD_DBM_INJECT_SQL_BASEHASH
Type: boolean
Default: false
Enables the injection of a “base hash” in SQL queries when DBM propagation is also enabled. This base hash is used to find matching spans, and enrich the queries with related values.
DD_DBM_PROPAGATION_MODE
Type: string
Default: disabled
Enables linking between data sent from APM and the Database Monitoring product when set to service or full. The service option enables the connection between DBM and APM services. The full option enables connection between database spans with database query events. Available for Postgres and MySQL.

Trace Logging

(6)

Tracer log output settings: log levels, log file paths, log rotation, and startup diagnostics.

DD_LOGGING_SERVICE
Type: string
Aliases:DD_LOGGING_SERVICE_NAME
Sets the service name reported by the logging integration. When unset, the integration falls back to DD_LOGGING_SERVICE_NAME and then to the global service name.
DD_TRACE_DEBUG
Type: boolean
Default: false
Aliases:OTEL_LOG_LEVEL

Enables debug mode for the SDK. When set, the SDK emits verbose log messages for troubleshooting. Takes precedence over DD_TRACE_LOG_LEVEL when active. Use OTEL_LOG_LEVEL as an alias.

Language-specific notes:

  • PHP: log messages are written to the device or file set in the PHP error_log INI setting. The actual value may differ from php -i output because it can be overridden in PHP-FPM/Apache configuration files.
DD_TRACE_LOG_FILE
Type: string
Specifies a log file. If none is specified, logs go to the default PHP error location. To debug datadog-ipc-helper issues (for example, submission of telemetry), you must specify the log file.
DD_TRACE_LOG_FILE_SIZE_BYTES
Type: int
Default: 15728640
Maximum size, in bytes, of the ddtrace log file specified by DD_TRACE_LOG_FILE before it is rotated. When the active log file exceeds this size, one backup file is created, so total on-disk log storage is roughly 2 * DD_TRACE_LOG_FILE_SIZE_BYTES. Has no effect unless DD_TRACE_LOG_FILE is set.
DD_TRACE_LOG_LEVEL
Type: string
Aliases:DD_LOG_LEVEL
A string for the minimum log level for the tracer to use when debug logging is enabled. Possible levels are info, warn, error, debug.
DD_TRACE_LOGGING_RATE
Type: int
Default: 60
Sets the number of seconds between identical log messages for Tracer log files. Default value is 0 and setting to 0 disables rate limiting.

Continuous Profiling

(27)

Continuous Profiler configuration: enable/disable, upload settings, profiling types, engine options, code hotspots, endpoint profiling, and experimental features.

DD_PROFILING_AGENTLESS
Type: boolean
Default: false
Enables agentless profile upload, sending profiles directly to the Datadog backend instead of through a Datadog Agent.
DD_PROFILING_API_TIMEOUT_MS
Type: int
Default: 10000
Sets the timeout in milliseconds for the profiler’s HTTP API uploads. If the Datadog backend does not respond within this duration, profiling events for that upload are dropped. Must be a non-negative integer.
DD_PROFILING_CAPTURE_PCT
Type: decimal
Default: 1.0
Sets the percentage of profiling events (such as memory allocations) that the profiler captures. Must be a value between 0 and 100; higher values increase profile fidelity but slow down program execution. Defaults to 1.0 when unset.
DD_PROFILING_ENABLE_ASSERTS
Type: boolean
Default: false
When enabled, turns on internal debug assertions in the profiler. With assertions on, profiling code raises AssertionError on unexpected internal state (for example, in lock acquire/release sampling) instead of silently swallowing it. Intended for debugging the profiler itself; leave disabled in production.
DD_PROFILING_ENABLE_CODE_PROVENANCE
Type: boolean
Default: true
Controls whether the profiler attaches code provenance metadata to uploaded profiles. Code provenance describes which packages and versions the profiled code came from, helping correlate profiling data with deployed dependencies. When disabled, profiles are uploaded without this provenance information.
DD_PROFILING_ENABLED
Type: boolean
Default: false
Aliases:DD_EXPERIMENTAL_PROFILING_ENABLED
Enables the continuous profiler, which collects CPU, heap, goroutine, and other runtime profiles and uploads them to Datadog.
DD_PROFILING_ENDPOINT_COLLECTION_ENABLED
Type: boolean
Default: true
Aliases:DD_PROFILING_EXPERIMENTAL_ENDPOINT_COLLECTION_ENABLED
Controls whether spans add a pprof label with the top-level request endpoint so profiles can be grouped by endpoint in the Datadog UI.
DD_PROFILING_EXCEPTION_COLLECT_MESSAGE
Type: boolean
Default: false
When enabled, the exception profiler attaches the exception message string to each sampled exception event. Disabled by default because exception messages can contain sensitive data. Only takes effect when the exception profiler itself is enabled.
DD_PROFILING_EXCEPTION_ENABLED
Type: boolean
Default: false
Enables exception-event profiling so exception-heavy code paths appear in profiles. Useful when diagnosing error storms or control-flow via exceptions.
DD_PROFILING_EXCEPTION_SAMPLING_INTERVAL
Type: int
Default: 100
Sets the average number of raised exceptions between samples taken by the exception profiler, using a Poisson distribution. Lower values sample more frequently but add more overhead. Must be a positive integer (>= 1). Only applies when the exception profiler is enabled.
DD_PROFILING_HEAP_ENABLED
Type: boolean
Default: true
If set to true, enables Live Heap profiling (in Preview). Defaults to DD_PROFILING_PROFILERS. Setting it to false overrules DD_PROFILING_PROFILERS entries.
DD_PROFILING_HEAP_SAMPLE_SIZE
Type: int
Sets the average number of bytes allocated between samples taken by the heap memory profiler. Lower values produce more frequent samples (higher fidelity, more overhead); higher values reduce overhead. When unset, the value is automatically derived from the host’s total memory, with a minimum of 1 MiB. Setting it to 0 disables heap sampling.
DD_PROFILING_IGNORE_PROFILER
Type: boolean
Default: false
Deprecated. When enabled, the profiler omits its own threads from the generated profiling data, so frames belonging to the profiler itself are excluded from stack and memory allocation samples. When unset, profiler threads are included in profiles.
DD_PROFILING_LOCK_ENABLED
Type: boolean
Default: true
If this config is set to false, the lock profile collection will be disabled
DD_PROFILING_LOCK_NAME_INSPECT_DIR
Type: boolean
Default: true
Controls whether the lock profiler inspects the attributes of local and global variables to recover the name of a sampled lock. When enabled, locks held as attributes on an object are reported under the attribute name (e.g. MyClass.my_lock) rather than as anonymous locks. Disable to skip this inspection if it interferes with third-party descriptors that misbehave on attribute access.
DD_PROFILING_MAX_FRAMES
Type: int
Default: 64
Maximum number of stack frames captured per thread sample in profiles.
DD_PROFILING_MAX_TIME_USAGE_PCT
Type: decimal
Default: 1.0
Caps the share of wall-clock time the stack profiler is allowed to spend gathering samples and computing statistics, expressed as a percentage. The profiler dynamically adjusts its sampling interval to stay under this budget. Must be greater than 0 and less than or equal to 100. Defaults to 1.0 (1%).
DD_PROFILING_MEMORY_ENABLED
Type: boolean
Default: true
Controls whether the memory profiler is enabled. When enabled, the profiler collects memory allocation samples from your application and reports them to Datadog. When disabled, no memory allocation profiles are produced, but other profile types (CPU, heap, lock, etc.) continue to run if they are enabled. Defaults to enabled.
DD_PROFILING_MEMORY_EVENTS_BUFFER
Type: int
Default: 16
Sets the size of the events buffer used by the memory profiler. Higher values let the profiler retain more memory allocation events between flushes; lower values reduce memory overhead at the cost of potentially dropping events. Must be a non-negative integer. When unset, defaults to 16.
DD_PROFILING_PYTORCH_ENABLED
Type: boolean
Default: false
Controls whether the PyTorch profiler collector is started as part of the Datadog profiler. When enabled, the profiler wraps torch.profiler usage to capture ML framework profiling events alongside standard Python profiling data. Disabled by default.
DD_PROFILING_PYTORCH_EVENTS_LIMIT
Type: int
Default: 1000000
Sets the maximum number of events the PyTorch profiler records during each collection cycle. When the number of captured events exceeds this limit, a random subsample of this size is kept and the rest are dropped. Must be a non-negative integer; defaults to 1000000 when unset.
DD_PROFILING_SAMPLE_POOL_CAPACITY
Type: int
Default: 4
Sets the number of profiler Sample objects kept in an internal pool for reuse. Increasing the capacity can reduce overhead from frequently allocating and deallocating Sample objects during profile collection. Must be a non-negative integer; defaults to 4 when unset.
DD_PROFILING_STACK_ENABLED
Type: boolean
Default: true
Controls whether the stack profiler is enabled. The stack profiler captures CPU and wall-time samples by periodically collecting Python stack traces from running threads, and is the primary source of CPU/wall-time data shown in the Datadog Profiler. When disabled, no stack samples are collected and related collectors (such as asyncio and threading instrumentation that depend on the stack profiler) are also turned off. If the underlying stack module cannot be loaded, this is forced off regardless of the configured value.
DD_PROFILING_STACK_NATIVE_FRAMES
Type: boolean
Default: true
Controls whether the stack profiler captures native (C/C++) function frames in addition to Python frames. Only takes effect on Python 3.12 and newer; on earlier versions the setting is ignored. When unset, native frame capture is enabled.
DD_PROFILING_STACK_UVLOOP
Type: boolean
Default: true
Controls whether the stack profiler enables uvloop-aware async profiling. When enabled, the profiler hooks into uvloop event loops so that asynchronous task stacks running on uvloop are captured correctly, including skipping the uvloop wrapper frame in task stacks. When disabled, uvloop event loops are not instrumented and async stacks running on uvloop may be incomplete or attributed to the wrapper frame. Defaults to enabled.
DD_PROFILING_TIMELINE_ENABLED
Type: boolean
Default: true
Aliases:DD_PROFILING_EXPERIMENTAL_TIMELINE_ENABLED

Enable the timeline profile type

Note: This supersedes the DD_PROFILING_EXPERIMENTAL_TIMELINE_ENABLED environment variable. (datadog.profiling.experimental_timeline_enabled INI setting), If both are set, this one takes precedence.

Language-specific notes:

  • PHP: This supersedes the datadog.profiling.experimental_timeline_enabled INI setting, which was available since 0.89
DD_PROFILING_UVLOOP
Type: boolean
Default: true
Controls whether the profiler enables uvloop-aware async profiling. When enabled, the profiler hooks into uvloop event loops so async tasks running on uvloop are captured in stack profiles alongside regular asyncio tasks. Disable to skip uvloop instrumentation if it causes issues in your application.

Application Security

(41)

Application Security configuration: ASM threat detection and blocking, user event tracking, IAST vulnerability detection, API Security schema discovery, and error tracking.

DD_API_SECURITY_DOWNSTREAM_BODY_ANALYSIS_SAMPLE_RATE
Type: decimal
Default: 0.5
Defines the probability of a downstream request body being sampled, or said differently, defines the overall number of requests for which the request and response body should be sampled / analysed.
DD_API_SECURITY_ENABLED
Type: boolean
Default: true
Aliases:DD_EXPERIMENTAL_API_SECURITY_ENABLED
Controls whether API Security features are enabled. If unset, API Security is enabled by default.
DD_API_SECURITY_ENDPOINT_COLLECTION_ENABLED
Type: boolean
Default: true
Controls whether API endpoint definitions are collected and reported for use in API Catalog. Disable to suppress endpoint discovery.
DD_API_SECURITY_ENDPOINT_COLLECTION_MESSAGE_LIMIT
Type: int
Default: 300
Sets the maximum number of API endpoints included in a single endpoint-collection telemetry message. If unset, a default limit is used.
DD_API_SECURITY_MAX_DOWNSTREAM_REQUEST_BODY_ANALYSIS
Type: int
Default: 1
The maximum number of downstream requests per request for which the request and response body should be analysed.
DD_API_SECURITY_PARSE_RESPONSE_BODY
Type: boolean
Default: true
Enables the parsing of the response body in the API Security module. Defaults to true
DD_API_SECURITY_REQUEST_SAMPLE_RATE
Type: decimal
Default: 0.1
Sets the sampling rate for API Security schema extraction. Values are clamped to the range 0.0 to 1.0; if unset or invalid, a default rate is used.
DD_APPSEC_AUTO_USER_INSTRUMENTATION_MODE
Type: string
Sets AppSec automated user instrumentation mode (user ID collection mode). Supported values include identification/ident, anonymization/anon, and disabled.
DD_APPSEC_AUTOMATED_USER_EVENTS_TRACKING
Type: string
Default: safe
Controls automated user events tracking for AppSec, including enabling/disabling it and selecting a tracking mode. Deprecated; prefer the appsec.auto_user_instrumentation.mode setting.
DD_APPSEC_AUTOMATED_USER_EVENTS_TRACKING_ENABLED
Type: boolean
Default: true
Enables automatic emission of AppSec user lifecycle signals (login success/failure, signup, authenticated user) into span metadata. Use when you want account-abuse and auth-related detections without manually emitting SDK events.
DD_APPSEC_ENABLED
Type: boolean
Default: false
Enables or disables the AppSec product inside the tracer. When enabled, the tracer initializes the AppSec module (in-app WAF, header/body collection, and AppSec telemetry).
DD_APPSEC_HTTP_BLOCKED_TEMPLATE_HTML
Type: string
Path to a local HTML template file that will be returned when a request is blocked and the response should be HTML. If unset or invalid, the tracer uses the default blocking HTML template defined by the product RFC. The tracer decides HTML or JSON according to Accept header or the block action’s parameters.
DD_APPSEC_HTTP_BLOCKED_TEMPLATE_JSON
Type: string
Path to a local JSON template file that will be returned when a request is blocked and the response should be JSON. If unset or invalid, the tracer uses the default blocking HTML template defined by the product RFC. The tracer decides HTML or JSON according to Accept header or the block action’s parameters.
DD_APPSEC_MAX_STACK_TRACE_DEPTH
Type: int
Default: 32
Aliases:DD_APPSEC_MAX_STACKTRACE_DEPTH
Maximum number of stack frames retained for any stack trace attached to an AppSec event. When the limit is reached, deeper frames are truncated and the top-of-stack frames are preserved. Lower the value to reduce event payload size.
DD_APPSEC_MAX_STACK_TRACE_DEPTH_TOP_PERCENT
Type: int
Default: 75
When the tracer must trim a stacktrace, this value controls how much of the top portion of the stacktrace is preserved at higher fidelity (a percentage). This lets implementations keep more of the top frames (most actionable) while trimming the less usefully deep frames
DD_APPSEC_MAX_STACK_TRACES
Type: int
Default: 2
Aliases:DD_APPSEC_MAX_STACKTRACES
Limits how many separate stacktraces are captured and attached to an AppSec/IAST event to keep payload sizes reasonable. Evidence stacktraces are useful for triage, but unbounded capture can leak sensitive data and consume excessive bandwidth; this limit balances evidence value and safety. Set to 0 to collect all.
DD_APPSEC_OBFUSCATION_PARAMETER_KEY_REGEXP
Type: string
A regular expression used by the AppSec obfuscator to identify parameter keys that must cause full redaction. When any key_path string matches this regexp the entire parameter is replaced by <redacted by datadog>. The default key regexp matches common secret/key names (password, token, authorization, jwt, etc.) an empty string disables the key regexp
DD_APPSEC_OBFUSCATION_PARAMETER_VALUE_REGEXP
Type: string
Regular expression used to find and redact sensitive substrings inside parameter values and highlights. Matches are replaced with <redacted by datadog>. This regexp complements the key regexp: the key regexp takes precedence; when no key match exists, the value regexp runs. The default pattern targeted at tokens, JWTs, private key blocks, and other credential shapes. Empty string disables the value regexp
DD_APPSEC_RASP_ENABLED
Type: boolean
Default: true
Turns on the tracer’s RASP / Exploit Prevention capabilities. When enabled the tracer runs synchronous, pre-execution checks and may generate block actions or exploit signals. RASP may have separate activation and implementation details per language; enabling it usually activates extra synchronous instrumentation and additional evidence capture for detections
DD_APPSEC_RULES
Type: string
Override the default rules file provided. Must be a path to a valid JSON rules file
DD_APPSEC_SCA_ENABLED
Type: boolean
Enables the tracer’s runtime Software Composition Analysis (Runtime SCA) capability, which reports runtime dependency/SBOM information and powers runtime vulnerability detection. Useful for testing and demonstrations as well as production runtime vulnerability workflows; SCA may have billing/usage implications and language compatibility constraints described in the SCA runbooks
DD_APPSEC_STACK_TRACE_ENABLED
Type: boolean
Default: true
Aliases:DD_APPSEC_STACKTRACE_ENABLED
Enables security-related stack traces generation when security events occur.
DD_APPSEC_TRACE_RATE_LIMIT
Type: int
Default: 100
Controls the maximum amount of AppSec traces, per second.
DD_APPSEC_WAF_TIMEOUT
Type: decimal
Limits the WAF synchronous execution time (in microseconds).
DD_ERROR_TRACKING_HANDLED_ERRORS
Type: string
Controls whether Error Tracking reports handled errors from user code, third-party gems, or both.
DD_ERROR_TRACKING_HANDLED_ERRORS_INCLUDE
Type: array
Comma-separated list of paths, file names, or gem names whose handled errors should be reported by Error Tracking.
DD_IAST_DEDUPLICATION_ENABLED
Type: boolean
Default: true
Enables or disables vulnerability deduplication detection. When enabled, a vulnerability is only reported once in the lifetime of an app, instead of on every occurrence. Default value is true (enabled).
DD_IAST_ENABLED
Type: boolean
Default: false
Enables or disables IAST. Default value is false (disabled).
DD_IAST_MAX_CONCURRENT_REQUESTS
Type: int
Default: 2
Maximum number of requests to be analyzed by IAST concurrently. Default value is 2.
DD_IAST_MAX_RANGE_COUNT
Type: int
Default: 30
IAST: maximum number of tainted ranges stored per tainted object/value. If more ranges are produced, they are truncated to this limit. Only used in DEFAULT detection mode; in FULL detection mode this is unlimited. Default (in DEFAULT mode): 10.
DD_IAST_REDACTION_ENABLED
Type: boolean
Default: true
Enables or disables IAST redaction of sensitive data. Default value is in TracerSettings.
DD_IAST_REDACTION_NAME_PATTERN
Type: string
Default: (?i)^.*(?:p(?:ass)?w(?:or)?d|pass(?:_?phrase)?|secret|(?:api_?|private_?|public_?|access_?|secret_?)key(?:_?id)?|password|token|username|user_id|last.name|consumer_?(?:id|key|secret)|sign(?:ed|ature)?|auth(?:entication|orization)?)
Custom regex pattern to obfuscate source keys in IAST. Default value is in TracerSettings.
DD_IAST_REDACTION_VALUE_PATTERN
Type: string
Default: (?i)bearer\s+[a-z0-9\._\-]+|token:[a-z0-9]{13}|password|gh[opsu]_[0-9a-zA-Z]{36}|ey[I-L][\w=-]+\.ey[I-L][\w=-]+(\.[\w.+\/=-]+)?|[\-]{5}BEGIN[a-z\s]+PRIVATE\sKEY[\-]{5}[^\-]+[\-]{5}END[a-z\s]+PRIVATE\sKEY|ssh-rsa\s*[a-z0-9\/\.+]{100,}
Custom regex pattern to obfuscate source values in IAST. Default value is in TracerSettings.
DD_IAST_REQUEST_SAMPLING
Type: decimal
Default: 30.0
IAST: request sampling percentage for analysis (overhead control). Used by the IAST overhead controller to decide which requests are analyzed. Values <= 0 are treated as 100% (it does not disable IAST). In FULL detection mode the sampling is forced to 100%. Default (in DEFAULT mode): 33%.
DD_IAST_SECURITY_CONTROLS_CONFIGURATION
Type: string
IAST: configures custom security controls (sanitizers / input validators) via a semicolon-separated configuration string. When set, the tracer installs a transformer that instruments the specified classes/methods so IAST can mark data as validated/sanitized for specific vulnerability types.
DD_IAST_STACK_TRACE_ENABLED
Type: boolean
Default: true
Aliases:DD_IAST_STACKTRACE_ENABLED
IAST: when enabled (default), captures a user-code stack trace and attaches it to IAST vulnerability reports (via a stack id). Useful for locating where vulnerable code executed. This also accepts the deprecated alias DD_IAST_STACKTRACE_ENABLED.
DD_IAST_TELEMETRY_VERBOSITY
Type: string
Default: INFORMATION
IAST: controls IAST telemetry verbosity (OFF, MANDATORY, INFORMATION, DEBUG). When tracer telemetry is disabled, this is forced to OFF. Default: INFORMATION.
DD_IAST_TRUNCATION_MAX_VALUE_LENGTH
Type: int
Default: 250
Default value is 250
DD_IAST_VULNERABILITIES_PER_REQUEST
Type: int
Default: 2
IAST: maximum number of vulnerabilities that can be reported per request (quota/overhead control). In FULL detection mode this limit is removed; in DEFAULT detection mode the default is 2.
DD_IAST_WEAK_CIPHER_ALGORITHMS
Type: string
IAST: regular expression (matched against the uppercased cipher algorithm id) that defines which cipher algorithms are considered weak. When a used cipher algorithm matches this pattern, IAST reports a WEAK_CIPHER vulnerability.
DD_IAST_WEAK_HASH_ALGORITHMS
Type: array
Default: md5,sha1
Controls which weak hashing algorithms are reported.

Dynamic Instrumentation & Debugging

(11)

Remote debugging capabilities: Dynamic Instrumentation for live probes, Exception Replay for automatic variable capture, Symbol Database for source-level debugging, and Code Origin for Spans for linking spans back to source code.

DD_CODE_ORIGIN_FOR_SPANS_ENABLED
Type: boolean
Default: true
Enables code origin for spans behavior in the tracer. When disabled, related data collection and processing are skipped.
DD_DYNAMIC_INSTRUMENTATION_DIAGNOSTICS_INTERVAL
Type: int
Default: 3600
Interval (seconds) at which probe diagnostic/status messages (received/installed/emitting/errors) may be re-emitted
DD_DYNAMIC_INSTRUMENTATION_ENABLED
Type: boolean
Default: false
Enables Dynamic Instrumentation, allowing log probes and metric probes to be added to running services from the Datadog UI without redeploying.
DD_DYNAMIC_INSTRUMENTATION_PROBE_FILE
Type: string
Path to a local probe definition JSON file. When set, the tracer loads probe definitions from this file at startup instead of subscribing to remote configuration.
DD_DYNAMIC_INSTRUMENTATION_REDACTED_IDENTIFIERS
Type: array
Comma-separated list of additional identifier keywords to redact in captured snapshot data
DD_DYNAMIC_INSTRUMENTATION_REDACTED_TYPES
Type: array
Comma-separated list of object types to redact from dynamic logs and snapshots. Supports * wildcards (e.g. Secret* matches SecretKey).
DD_DYNAMIC_INSTRUMENTATION_REDACTION_EXCLUDED_IDENTIFIERS
Type: array
Environment variable to exclude identifiers from redaction
DD_DYNAMIC_INSTRUMENTATION_UPLOAD_INTERVAL_SECONDS
Type: decimal
Default: 1.0
Interval in seconds between uploads of probe data.
DD_EXCEPTION_REPLAY_CAPTURE_MAX_FRAMES
Type: int
Default: 8
The maximum number of captured frames for Exception Replay
DD_EXCEPTION_REPLAY_ENABLED
Type: boolean
Default: false
Exception Replay (Live Debugging): enables the Exception Replay product. When enabled (for example via Remote Config), the tracer starts/stops the Exception Replay subsystem. This key is also accepted as a backward-compatible alias for DD_EXCEPTION_DEBUGGING_ENABLED.
DD_SYMBOL_DATABASE_UPLOAD_ENABLED
Type: boolean
Default: true
Symbol Database (SymDB): enables uploading symbol information (for Live Debugging / Dynamic Instrumentation). Default: true.

CI Visibility

(34)

CI Visibility and Test Optimization: test reporting, code coverage collection, git metadata, flaky test management, test skipping, and CI provider integration.

DD_ACTION_EXECUTION_ID
Type: string
Sets the action execution ID reported as CI metadata for AWS CodePipeline builds. This value is used as the CI job identifier when running a CodeBuild job initiated by CodePipeline.
DD_CIVISIBILITY_AGENTLESS_ENABLED
Type: boolean
Default: false
Enables agentless mode for CI Visibility, sending test data directly to the Datadog intake instead of through a local Agent.
DD_CIVISIBILITY_AGENTLESS_URL
Type: string
Overrides the intake base URL used for agentless CI test reporting. When set, payloads are sent to this URL instead of the default site-based intake URL.
DD_CIVISIBILITY_AUTO_INSTRUMENTATION_PROVIDER
Type: string
Marks CI test sessions as running under an auto-instrumentation workflow. Any non-empty value enables this marker for telemetry.
DD_CIVISIBILITY_EARLY_FLAKE_DETECTION_ENABLED
Type: boolean
Default: true
Enables CI Visibility Early Flake Detection (EFD), which can run selected tests multiple times early to detect flakiness (based on backend-provided execution settings).
DD_CIVISIBILITY_ENABLED
Type: boolean
Default: true
Enabling or disabling CI Visibility
DD_CIVISIBILITY_FLAKY_RETRY_COUNT
Type: int
Default: 5
Can be set to any non-negative number to change the maximum number of retries per test case.
DD_CIVISIBILITY_FLAKY_RETRY_ENABLED
Type: boolean
A kill switch for the auto test retries feature.
DD_CIVISIBILITY_ITR_ENABLED
Type: boolean
Default: true
Enables or disables Intelligent Test Runner in CI Visibility. Default Value is false (disabled).
DD_CIVISIBILITY_LOG_LEVEL
Type: string
Default: info
Sets the log level used by the CI Visibility logger handler installed by test runner integrations (such as pytest and unittest). Accepts standard Python logging levels (debug, info, warning, error, critical), as well as the special value none to disable the CI Visibility logger takeover entirely. Defaults to info. Ignored when debug mode is enabled.
DD_CIVISIBILITY_RUM_FLUSH_WAIT_MILLIS
Type: int
Default: 500
CI Visibility (Selenium): after calling window.DD_RUM.stopSession() at the end of a browser test, waits this many milliseconds before proceeding to allow RUM data to flush (default: 500ms).
DD_CIVISIBILITY_TOTAL_FLAKY_RETRY_COUNT
Type: int
Default: 1000
Maximum total number of automatic test retries allowed across the entire CI test session, applied when automatic flaky-test retries are enabled.
DD_CIVISIBILITY_USE_BETA_WRITER
Type: boolean
Default: false
When enabled, CI Visibility uses the beta writer pipeline: a dedicated CI Visibility tracer with its own context provider is created, and a span forwarder is attached to the global tracer so test spans are routed through the beta path. When disabled, the standard CI Visibility writer and the global tracer are used.
DD_CUSTOM_TRACE_ID
Type: string
Custom trace ID propagated by the Jenkins Datadog Plugin, used to correlate Jenkins pipeline executions with traces emitted by the application under test.
DD_GIT_BRANCH
Type: string
Overrides the Git branch value used by CI Visibility for repository and commit correlation.
DD_GIT_COMMIT_AUTHOR_DATE
Type: string
Overrides the commit-author date, in ISO 8601 format, reported as CI metadata.
DD_GIT_COMMIT_AUTHOR_EMAIL
Type: string
Overrides the git commit author email reported as CI metadata.
DD_GIT_COMMIT_AUTHOR_NAME
Type: string
Overrides the git commit author name reported as CI metadata.
DD_GIT_COMMIT_COMMITTER_DATE
Type: string
Overrides the commit-committer date, in ISO 8601 format, reported as CI metadata.
DD_GIT_COMMIT_COMMITTER_EMAIL
Type: string
Overrides the git commit committer email reported as CI metadata.
DD_GIT_COMMIT_COMMITTER_NAME
Type: string
Overrides the git commit committer name reported as CI metadata.
DD_GIT_COMMIT_MESSAGE
Type: string
Overrides the git commit message reported as CI metadata.
DD_GIT_PULL_REQUEST_BASE_BRANCH
Type: string
CI Visibility: sets the pull request base/target branch name, used to populate pull request info and CI git tags (for example, git.pull_request.base_branch) when user-supplied git metadata is needed.
DD_GIT_PULL_REQUEST_BASE_BRANCH_SHA
Type: string
Overrides the pull request base commit SHA reported as git metadata for CI features. Use this to set the base commit when it cannot be detected automatically.
DD_GIT_REPOSITORY_URL
Type: string
Overrides the git repository URL reported as CI metadata and used for git metadata tagging when enabled. Any embedded credentials in the URL are stripped before use.
DD_GIT_TAG
Type: string
Overrides the Git tag used by CI Visibility for repository and release correlation.
DD_PIPELINE_EXECUTION_ID
Type: string
Sets the pipeline execution ID reported as CI metadata for AWS CodePipeline builds. This value is used as the CI pipeline identifier when running a CodeBuild job initiated by CodePipeline.
DD_TEST_DEBUG
Type: boolean
When enabled, sets the Datadog test-optimization logger (ddtrace.testing) to DEBUG level so verbose diagnostic output is emitted while running tests. When unset (or falsy), the logger uses INFO level. DD_TRACE_DEBUG also enables this debug output.
DD_TEST_MANAGEMENT_ATTEMPT_TO_FIX_RETRIES
Type: int
Overrides the number of retry executions for tests flagged as “attempt to fix”. When unset, the value from backend/remote settings is used.
DD_TEST_MANAGEMENT_ENABLED
Type: boolean
Enables or disables the Test Management feature.
DD_TEST_OPTIMIZATION_ENV_DATA_FILE
Type: string
Sets the path to a JSON file containing CI/environment metadata used for test reporting. If not set, a default file next to the test binary is used.
DD_TEST_SESSION_NAME
Type: string
Overrides the auto-generated test session name reported to CI Visibility. When unset, the tracer builds a name from the detected CI provider, repository, and branch information.
DD_TEST_VISIBILITY_SERVICE
Type: string
Aliases:DD_TEST_VISIBILITY_SERVICE_NAME
Sets the service name reported by the test_visibility integration. When unset, the integration falls back to DD_TEST_VISIBILITY_SERVICE_NAME and then to the default service name "default_test_visibility_service".
DD_TRACE_GIT_METADATA_ENABLED
Type: boolean
Default: true
When enabled, the tracer attaches Git repository URL and commit SHA tags to root spans, allowing traces to be linked back to the corresponding source code in the Datadog UI.

Crash Tracking & Diagnostics

(8)

Crash tracking for capturing and reporting application crashes, and heap snapshot configuration.

DD_CRASHTRACKING_COLLECT_ALL_THREADS
Type: boolean
Default: true
Whether to collect stack traces from all threads when a crash is handled.
DD_CRASHTRACKING_CREATE_ALT_STACK
Type: boolean
Default: true
When enabled, the crashtracker allocates its own alternate signal stack used to handle fatal signals during a crash. The Python runtime allocates a very small alternate stack by default, so this is typically combined with DD_CRASHTRACKING_USE_ALT_STACK to ensure the alternate stack is large enough for the crash handler to run reliably.
DD_CRASHTRACKING_DEBUG_URL
Type: string
Overrides the destination URL used by the crashtracker to send crash reports. When unset, the crashtracker sends reports to the trace agent URL configured for the tracer. Intended for development and debugging scenarios where crash reports must be redirected to an alternate endpoint.
DD_CRASHTRACKING_ENABLED
Type: boolean
Default: true
Enables Crash Tracking. When enabled, the tracer initializes crash tracking and configures JVM crash/OOM hooks (for example, -XX:OnError and -XX:OnOutOfMemoryError) to run Datadog-provided scripts that upload hs_err_pid*.log crash logs and OOME notifications. Default: true.
DD_CRASHTRACKING_MAX_THREADS
Type: int
Default: 128
Maximum number of threads to collect stack traces for when collect_all_threads is enabled.
DD_CRASHTRACKING_STDERR_FILENAME
Type: string
Sets the destination filename to which the crashtracker redirects standard error output captured during a crash. When unset, crashtracker stderr is not redirected to a file.
DD_CRASHTRACKING_STDOUT_FILENAME
Type: string
Sets the destination filename to which the crashtracker receiver process writes its standard output. When unset, the receiver’s stdout is not redirected to a file.
DD_CRASHTRACKING_USE_ALT_STACK
Type: boolean
Default: true
Controls whether the crash tracker installs its signal handler on an alternate stack so it can still capture a crash report when the main thread stack is exhausted or corrupted. When unset, defaults to true. Typically used together with DD_CRASHTRACKING_CREATE_ALT_STACK, since the Python runtime allocates a very small alternate stack by default.

Log Submission & Correlation

(3)

Direct log submission to Datadog, agentless log forwarding, log injection for trace-log correlation, and OpenTelemetry log export.

DD_AGENTLESS_LOG_SUBMISSION_ENABLED
Type: boolean
Default: false
Enables direct log submission to Datadog without routing logs through the Datadog Agent.
DD_LOGS_INJECTION
Type: boolean
Default: true

Enables or disables automatic injection of correlation identifiers (trace ID, span ID) into application logs.

Language-specific notes:

  • .NET: Your logger needs a source that sets the trace_id mapping correctly. The default source for .NET applications, csharp, does this automatically.
DD_LOGS_OTEL_ENABLED
Type: boolean
Default: false
Enables collection and export of logs produced via the OpenTelemetry Logs API.

Runtime Metrics

(4)

Runtime metrics collection and DogStatsD connection configuration for metric submission.

DD_DOGSTATSD_HOST
Type: string
Override the address of the trace Agent host that the default tracer attempts to submit DogStatsD metrics to. Use DD_AGENT_HOST to override DD_DOGSTATSD_HOST.
DD_DOGSTATSD_PORT
Type: int
Default: 8125
The port of the DogStatsD Agent that metrics are submitted to. If the Agent configuration sets dogstatsd_port or DD_DOGSTATSD_PORT to something other than the default 8125, then this tracing library DD_DOGSTATSD_PORT must match it.
DD_DOGSTATSD_URL
Type: string
Default: http://localhost:8125
The URL used to connect to the DogStatsD endpoint. Takes precedence over DD_AGENT_HOST and DD_DOGSTATSD_PORT. Supports udp:// or unix:// schemes only.
DD_RUNTIME_METRICS_ENABLED
Type: boolean
Default: false
Enables or disables the collection of runtime metrics (such as garbage collection stats, memory usage, and thread counts) for the application.

Data Streams Monitoring

(1)

Data Streams Monitoring for tracking end-to-end latency across message queues and streaming pipelines.

DD_DATA_STREAMS_ENABLED
Type: boolean
Default: false
Enables Data Streams Monitoring (DSM) and its checkpoint propagation. When enabled, the tracer registers the DSM propagator and reports pathway statistics and payloads.

Instrumentation Telemetry

(6)

Tracer self-reporting telemetry: heartbeat intervals, dependency and log collection, and telemetry forwarder configuration.

DD_INSTRUMENTATION_TELEMETRY_ENABLED
Type: boolean
Default: true
Allows Datadog to collect environmental and diagnostic information about your application and runtime to improve the product. Set to false to opt out of instrumentation telemetry.
DD_TELEMETRY_DEPENDENCY_COLLECTION_ENABLED
Type: boolean
Default: true
Enables the instrumentation telemetry dependency collector, which detects application dependencies at runtime and reports them to Datadog.
DD_TELEMETRY_HOST
Type: string
Sets the host of the DogStatsd server that receives the dogstatsd client’s own telemetry stats. When unset, telemetry stats are sent to the same host as regular metrics (the configured DogStatsd server).
DD_TELEMETRY_LOG_COLLECTION_ENABLED
Type: boolean
Default: true
Controls whether internal tracer logs are forwarded as part of instrumentation telemetry.
DD_TELEMETRY_METRICS_ENABLED
Type: boolean
Default: true
Controls whether instrumentation telemetry sends internal metrics.
DD_TELEMETRY_PORT
Type: int
Sets the port of the DogStatsd server that the bundled DogStatsd client uses to submit its own client telemetry stats. When unset, the client falls back to the main DogStatsd port (DD_DOGSTATSD_PORT or the configured port).

Remote Configuration

(1)

Remote Configuration for receiving live configuration updates from Datadog.

DD_REMOTE_CONFIGURATION_ENABLED
Type: boolean
Default: true
Aliases:DD_REMOTE_CONFIG_ENABLED
Enable or disable remote configuration.

OpenTelemetry Compatibility

(31)

Standard OpenTelemetry environment variables supported by Datadog SDKs: resource attributes, propagators, trace sampler, OTLP exporter configuration, and batch span processor settings.

DD_METRICS_OTEL_ENABLED
Type: boolean
Default: false
Enables OpenTelemetry metrics export. Metrics are disabled by default and are only enabled when this is set to a truthy value.
DD_TRACE_OTEL_ENABLED
Type: boolean
Default: false
Enables the Datadog SDK’s OpenTelemetry interoperability for traces.
OTEL_EXPORTER_OTLP_ENDPOINT
Type: string
Specifies the base URL for sending OTLP data for all signals unless overridden. Default (gRPC): http://localhost:4317 . Default (HTTP): http://localhost:4318 .
OTEL_EXPORTER_OTLP_HEADERS
Type: string
Description: Specifies a comma-separated list of key-value pairs to be used as headers on all outgoing OTLP requests (for example, api-key=key,other-config=value).
OTEL_EXPORTER_OTLP_LOGS_ENDPOINT
Type: string
Aliases:OTEL_EXPORTER_OTLP_ENDPOINT
URL for sending OTLP logs. Takes precedence over OTEL_EXPORTER_OTLP_ENDPOINT. Defaults to http://localhost:4317 for gRPC and http://localhost:4318/v1/logs for HTTP.
OTEL_EXPORTER_OTLP_LOGS_HEADERS
Type: string
Aliases:OTEL_EXPORTER_OTLP_HEADERS
Specifies a comma-separated list of key-value pairs to be used as headers on outgoing OTLP logs requests. Takes precedence over the general OTEL_EXPORTER_OTLP_HEADERS.
OTEL_EXPORTER_OTLP_LOGS_PROTOCOL
Type: string
Default: grpc
Aliases:OTEL_EXPORTER_OTLP_PROTOCOL
Specifies the OTLP transport protocol to be used for log data.
OTEL_EXPORTER_OTLP_LOGS_TIMEOUT
Type: int
Default: 10000
Aliases:OTEL_EXPORTER_OTLP_TIMEOUT
Specifies the timeout (in milliseconds) for a single outgoing OTLP logs request. Takes precedence over the general OTEL_EXPORTER_OTLP_TIMEOUT.
OTEL_EXPORTER_OTLP_METRICS_ENDPOINT
Type: string
Aliases:OTEL_EXPORTER_OTLP_ENDPOINT
If non-empty, used as the OTLP metrics endpoint. Otherwise falls back to OTEL_EXPORTER_OTLP_ENDPOINT, then to http://<DD_TRACE_AGENT_URL host>:4317/4318 based on protocol. For http/protobuf, /v1/metrics is appended if missing.
OTEL_EXPORTER_OTLP_METRICS_HEADERS
Type: string
Aliases:OTEL_EXPORTER_OTLP_HEADERS
Sets additional headers to include in OTLP exporter requests for metrics. When set, it takes precedence over OTEL_EXPORTER_OTLP_HEADERS for metrics export.
OTEL_EXPORTER_OTLP_METRICS_PROTOCOL
Type: string
Specifies the OTLP transport protocol to use for metrics data. Takes precedence over the general OTEL_EXPORTER_OTLP_PROTOCOL. Accepted values: grpc, http/protobuf, http/json.
OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE
Type: string
Description: Specifies the aggregation temporality to use for each instrument kind. Notes: This default value delta is Datadog’s recommended configuration and differs from the OpenTelemetry specification’s default.
OTEL_EXPORTER_OTLP_METRICS_TIMEOUT
Type: int
Used as the exporter network timeout (ms) for OTLP metrics requests. If set to 0, the library falls back to OTEL_EXPORTER_OTLP_TIMEOUT.
OTEL_EXPORTER_OTLP_PROTOCOL
Type: string
Description: Specifies the transport protocol to use for all signals unless overridden.
OTEL_EXPORTER_OTLP_TIMEOUT
Type: int
Default: 10000
Default timeout, in milliseconds, for OTLP export requests. Used as a fallback when a signal-specific timeout is not set.
OTEL_EXPORTER_OTLP_TRACES_ENDPOINT
Type: string
Aliases:OTEL_EXPORTER_OTLP_ENDPOINT

Configures the endpoint URL for OTLP trace submission, taking precedence over the fallback configuration OTEL_EXPORTER_OTLP_ENDPOINT. If the value of OTEL_EXPORTER_OTLP_ENDPOINT is used, then a signal-agnostic endpoint is assumed and a /v1/traces subpath must be appended when constructing the trace endpoint URL for http/protobuf and http/json protocols

Default value:

  • gRPC: “http://localhost:4317”
  • HTTP: “http://localhost:4318/v1/traces”
OTEL_EXPORTER_OTLP_TRACES_HEADERS
Type: string
Configuration key to set custom headers for OTLP metrics export. Takes precedence over general OTLP headers. Format: api-key=key,other=value.
OTEL_EXPORTER_OTLP_TRACES_PROTOCOL
Type: string
Configuration key to set the OTLP protocol for metrics export. Takes precedence over the general OTLP protocol setting. Valid values: grpc, http/protobuf, http/json.
OTEL_EXPORTER_OTLP_TRACES_TIMEOUT
Type: int
Default: 10000
Configuration key to set the request timeout for OTLP metrics export in milliseconds. Takes precedence over the general OTLP timeout setting.
OTEL_LOG_LEVEL
Type: string
Configuration key to set the log level.
OTEL_LOGS_EXPORTER
Type: string
Controls the OpenTelemetry logs exporter selection. This setting is not supported and is ignored.
OTEL_METRIC_EXPORT_INTERVAL
Type: int
Default: 10000
Interval, in milliseconds, between metric export attempts. The default of 10000 (10s) is Datadog’s recommended value and differs from the OpenTelemetry specification default of 60000 ms.
OTEL_METRIC_EXPORT_TIMEOUT
Type: int
Default: 7500
Maximum time, in milliseconds, allowed to collect and export a single batch of metrics. The default of 7500 (7.5s) is Datadog’s recommended value and differs from the OpenTelemetry specification default of 30000 ms.
OTEL_METRICS_EXPORTER
Type: string
Default: otlp
Specifies the OpenTelemetry metrics exporter. The only accepted values are otlp and none. Setting it to none disables both OTel metric emission and APM runtime metrics (equivalent to DD_RUNTIME_METRICS_ENABLED=false).
OTEL_PROPAGATORS
Type: array
Configures which propagators are used for extracting and injecting trace context.
OTEL_RESOURCE_ATTRIBUTES
Type: map
Set OpenTelemetry resource attributes as a list of (key, value) pairs.
OTEL_SDK_DISABLED
Type: string
Disables the Datadog SDK’s OpenTelemetry interoperability for all signals. Notes: When set to true, this effectively sets DD_TRACE_OTEL_ENABLED=false, DD_LOGS_OTEL_ENABLED=false, and DD_METRICS_OTEL_ENABLED=false. Ruby & Go SDKs: The OpenTelemetry SDK activates automatically upon import and configuration, so this setting is not applicable.
OTEL_SERVICE_NAME
Type: string
Sets the application’s default service name. Alias for DD_SERVICE when DD_SERVICE is not set.
OTEL_TRACES_EXPORTER
Type: string
Configuration key to set the exporter for traces. Only the value none is recognized, which is equivalent to setting trace export to disabled.
OTEL_TRACES_SAMPLER
Type: string
Sets the trace sampler via OpenTelemetry configuration and maps it to the tracer’s sample rate when the corresponding setting is not set. Parent-based samplers are supported; unsupported values are ignored.
OTEL_TRACES_SAMPLER_ARG
Type: string
OpenTelemetry traces sampler argument (otel.traces.sampler.arg / OTEL_TRACES_SAMPLER_ARG): used when OTEL_TRACES_SAMPLER=parentbased_traceidratio; the value is treated as the traceidratio sample rate and mapped to Datadog’s trace sample rate. Default: unset.

AI & LLM Observability

(16)

AI observability features: AI Guard content scanning, LLM Observability, and per-provider integration settings.

DD_AI_GUARD_BLOCK
Type: boolean
Default: true
Control blocking behavior when using evaluating a prompt using AI Guard inside auto instrumented package
DD_AI_GUARD_ENABLED
Type: boolean
Default: false
Enables AI Guard request inspection in the tracer; when disabled, AI Guard checks are skipped.
DD_AI_GUARD_ENDPOINT
Type: string
AI Guard: sets the base endpoint URL for the AI Guard REST API. If unset, defaults to https://app.<DD_SITE>/api/v2/ai-guard (the tracer appends /evaluate).
DD_AI_GUARD_MAX_CONTENT_SIZE
Type: int
Default: 524288
Max size of the content property set in the meta-struct
DD_AI_GUARD_MAX_MESSAGES_LENGTH
Type: int
Default: 16
Maximum number of conversational messages allowed to be set in the meta-struct
DD_AI_GUARD_TIMEOUT
Type: int
Default: 10000
Timeout used in calls to the AI Guard REST API in milliseconds (default 5000)
DD_LLMOBS_AGENTLESS_ENABLED
Type: boolean
Set to true to disable sending data that requires a Datadog Agent.
DD_LLMOBS_ENABLED
Type: boolean
Default: false
Toggle to enable submitting data to LLM Observability
DD_LLMOBS_EVALUATOR_SAMPLING_RULES
Type: string
Configures sampling rules for LLM Observability evaluators. Accepts a JSON-encoded list of rule objects, each requiring a sample_rate (float between 0.0 and 1.0) and optionally evaluator_label and/or span_name to scope the rule. When unset, all evaluator runs are sampled (no filtering). Invalid JSON or rules missing sample_rate are skipped and reported via telemetry.
DD_LLMOBS_INSTRUMENTED_PROXY_URLS
Type: string
Comma-separated list of base URLs that point to LLM proxies which already emit LLM Observability spans. When an outbound LLM call’s base URL matches one of these entries, the local LLM integration skips creating a duplicate LLM Observability span so the proxy-emitted span is preserved as the source of truth. Unset by default, meaning no proxy URLs are treated as pre-instrumented.
DD_LLMOBS_ML_APP
Type: string
Sets the default ML app name used for LLM Observability data. This value is required when LLM Observability is enabled.
DD_LLMOBS_OVERRIDE_ORIGIN
Type: string
Overrides the base URL used by LLM Observability when sending span and evaluation metric payloads in agentless mode, and when fetching prompts from the Prompt Registry. When unset, agentless writers send to https://llmobs-intake.<site> (or proxy through the Datadog Agent if not in agentless mode), and the Prompt Registry uses https://api.<site>, where <site> comes from DD_SITE. Set this to a full origin (scheme + host, optionally port) to redirect traffic to a custom endpoint, typically for testing or proxying.
DD_LLMOBS_PAYLOAD_SIZE_BYTES
Type: int
Default: 5242880
Maximum size in bytes of buffered LLM Observability events before the writer flushes the batch to the intake. When adding the next event would exceed this threshold, the current buffer is sent immediately. Defaults to 5242880 (5 MiB), matching the EVP intake payload limit.
DD_LLMOBS_PROJECT_NAME
Type: string
This config allows to configure the default LLM Observability project to use. It is required when using the Experiments and Datasets feature.
DD_LLMOBS_PROMPTS_CACHE_DIR
Type: string
Sets the directory used by LLM Observability to persist the file-based (“warm”) prompt cache that backs the Prompt Registry. Cached prompt entries are written to this location so they survive process restarts when file caching is enabled. When unset, the cache is stored under ~/.cache/datadog/llmobs/prompts, falling back to a temporary directory if no home directory is available. Paths starting with ~ are expanded.
DD_LLMOBS_SAMPLE_RATE
Type: decimal
Default: 1.0
Controls the sampling rate applied to LLM Observability payloads emitted by built-in LLM integrations (OpenAI, Anthropic, Bedrock, etc.). Accepts a float between 0.0 (drop all) and 1.0 (send all). When unset, all eligible LLM spans are sampled.

Instrumentation & Platform

(4)

Instrumentation setup and platform-specific configuration: auto-injection, third-party library detection, and platform adapters.

DD_INJECT_FORCE
Type: boolean
Default: false
Single Step Instrumentation (SSI): forces the tracer javaagent to load even when multiple JVM agents are detected. This bypasses SSI guardrails that would otherwise abort startup to avoid running multiple agents. Can be set via DD_INJECT_FORCE or system property dd.inject.force. Default: false.
DD_INSTRUMENTATION_CONFIG_ID
Type: string
Internal instrumentation configuration identifier attached to telemetry for remote-configuration correlation.
DD_THIRD_PARTY_DETECTION_EXCLUDES
Type: array
Default: []
Alias of DD_THIRD_PARTY_EXCLUDES. Live Debugging / Exception Replay: package prefixes to treat as first-party (exclude from the third-party library filter). This allowlist overrides the default third-party library list.
DD_THIRD_PARTY_DETECTION_INCLUDES
Type: array
Default: []
Comma-separated list of libraries to include in third-party detection. Default value is empty.

Miscellaneous

(2)

Configuration keys that don't fit into the other categories yet. Treat this list as a backlog: each key here should eventually find a real home.

DD_EXPERIMENTAL_FLAGGING_PROVIDER_ENABLED
Type: boolean
Default: false
Enables the experimental feature-flag provider that evaluates flags from remote configuration. If not enabled, the provider is a no-op and returns default values.
DD_EXPERIMENTAL_FLAGGING_PROVIDER_INITIALIZATION_TIMEOUT_MS
Type: int
Default: 10000
Timeout in milliseconds for OpenFeature provider initialization. If configuration is not received within this time, initialization fails. Can be configured via DD_EXPERIMENTAL_FLAGGING_PROVIDER_INITIALIZATION_TIMEOUT_MS environment variable.

Further Reading