Data Source Name (DSN)

Sentry automatically assigns you a Data Source Name (DSN) when you create a project to start monitoring events in your app.

What the DSN Does

The DSN tells the SDK where to send the events. If this value is not provided, the SDK will try to read it from the SENTRY_DSN environment variable. If that variable also does not exist, the SDK will just not send any events.

Where to Find Your DSN

If you forget your DSN, view Settings -> Projects -> Client Keys (DSN) in

The Parts of the DSN

The DSN configures the protocol, public key, server address, and project identifier. It is composed of the following parts:


For example:

Sentry.init({ dsn: "" });

Has the following settings:

The resulting POST request for a plain JSON payload would then transmit to

You can edit this page on GitHub.