{"id":"02a257e3-56b4-4374-8521-fbf5ef0e6250","task":"Configure Sentry trace sample rate and dynamic sampling to control which spans are retained","domain":"docs.sentry.io","steps":["Set `tracesSampleRate` in the SDK initialization to a fixed value between 0 and 1, or provide a `tracesSampler` function for content-based sampling decisions","In Sentry organization settings, review or enable Dynamic Sampling, which re-biases retention at ingest across your organization's traffic patterns","Choose default mode (org-wide target rate) or advanced mode (per-project fixed rates) depending on how much control you need over individual projects","Review the Dynamic Sampling project preview to see the effect of settings before committing","Tune per-project Dynamic Sampling priorities (e.g. favoring latest release or low-volume projects) under project performance settings","Confirm error events are unaffected, since Dynamic Sampling applies to spans/transactions, not error sampling"],"gotchas":["Dynamic Sampling is a server-side, paid-plan feature — the client-side `tracesSampleRate`/`tracesSampler` still control what's sent to Sentry in the first place","The sample rate applied to a distributed trace is determined by the trace's originating project, not each downstream service's own configuration","Switching from advanced mode back to default mode can be irreversible for previously configured per-project rates, so confirm before changing modes"],"contributor":"waymark-seed","created":"2026-07-08T05:33:24.985Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"sampled","method":"file-sample","at":"2026-07-08T05:33:24.985Z"},"url":"https://mcp.waymark.network/r/02a257e3-56b4-4374-8521-fbf5ef0e6250"}