// Engineering Log
Monitoring: Part 6 — Application Errors: Sentry and GlitchTip
Published on 2026-09-22
// Fast route
This article belongs to the topic Deploy and reliability.
Server metrics and logs don’t show everything. If an error occurred in the user’s browser or in a rare code path, the server may not log anything and the user may simply close the page. For such cases there are application error tracking systems: they receive the exception directly from the code along with the stack trace, release version, and request context, and they group identical errors into a single issue.
The best known of these is Sentry. Its open alternative, compatible with the same client libraries, is GlitchTip.
What an error tracking system gives you
- Stack trace with the exact location in code, including for minified JavaScript if source maps are uploaded.
- Grouping. A thousand identical exceptions — one issue with a counter, not a thousand emails.
- Context: browser, operating system, release version, page URL, sequence of events before the crash (breadcrumbs).
- Release association: you can see in which version the error appeared and whether it was fixed in the next release.
- Alerts about new errors and sharp increases in existing ones.
This is not a replacement for metrics and logs: Prometheus or Zabbix will tell you whether the server is alive and has enough resources, while Sentry will tell you what exactly broke in the code. An overview of metrics and alerts is in the first part of the series.
Sentry: cloud or self-hosted
Cloud Sentry (sentry.io). As of September 2026 the free Developer tier is for a single user and includes 5,000 errors and 5 million tracing spans per month. The Team tier for a team starts at $26/month when billed annually. You can’t pay a foreign service with a Russian card: Visa and Mastercard have not worked outside Russia since March 2022.
Sentry on your own server. The Sentry source code is distributed under the FSL-1.1-Apache-2.0 (Functional Source License). You can use and modify it for your own needs; building a competing service on top of it is prohibited; two years after release each version automatically switches to Apache 2.0. This is not an open license in the strict sense, but for internal use there are practically no restrictions.
A ready self-hosted build is the getsentry/self-hosted repository. Documentation requirements: 4 CPU cores, 16 GB RAM plus 16 GB swap (32 GB recommended), at least 20 GB disk, recent Docker and Docker Compose. It runs several databases and a message broker, so disk speed matters. For a small project this is heavy.
GlitchTip: a lightweight open alternative
GlitchTip is an open error-tracking system under the MIT license. It accepts events from Sentry client libraries, so the only code change is the DSN address. GlitchTip has a cloud version with a free tier up to 1,000 events per month, but its main advantage is ease of self-hosting: a few containers (web app, background workers, PostgreSQL, Redis) instead of dozens.
GlitchTip has fewer features: it lacks some performance analysis tools and session replay found in Sentry. For the task of “learning about errors and seeing stack traces” this is usually enough.
| Sentry (cloud) | Sentry (self-hosted) | GlitchTip | |
|---|---|---|---|
| License | — | FSL-1.1-Apache-2.0 | MIT |
| Where data is stored | at Sentry | with you | with you or in GlitchTip cloud |
| Server resources | not needed | from 16 GB RAM | a few gigabytes |
| Compatibility with Sentry SDK | yes | yes | yes |
Integrating the SDK
The process is the same for Sentry and GlitchTip: create a project, copy the DSN — the address to which the library sends events — and initialize the SDK as early as possible when the application starts.
JavaScript in the browser. Tracing is included in the main package; the separate @sentry/tracing is no longer needed:
npm install @sentry/browser --saveimport * as Sentry from "@sentry/browser";
Sentry.init({
dsn: "https://<key>@o<orgId>.ingest.sentry.io/<projectId>",
release: "my-app@1.4.2",
integrations: [Sentry.browserTracingIntegration()],
tracesSampleRate: 0.1,
});Python (Django, Flask, FastAPI are picked up automatically if installed):
pip install sentry-sdkimport sentry_sdk
sentry_sdk.init(
dsn="https://<key>@o<orgId>.ingest.sentry.io/<projectId>",
release="my-app@1.4.2",
traces_sample_rate=0.1,
)The value tracesSampleRate: 1.0 from the documentation examples means recording every request. For production workloads 5–10% is usually enough, otherwise your tracing quota will be exhausted in a few days.
Checking the integration is simple: throw a test exception in the code and make sure the event appears in the UI.
Source maps and releases
Frontend code in production is minified, and without source maps the stack trace points to line 1 of main.8f3a.js. The simplest way to set up uploading source maps is the wizard:
npx @sentry/wizard@latest -i sourcemapsIt will add uploading of maps to the build via the Sentry CLI. The association between maps and files is built by debug identifiers (Debug IDs), so you don’t need to change built files manually. The release version in release must match what the build knows — then you can see in the UI in which version the error appeared. Uploading maps and creating the release should be done in the CI pipeline, not from a developer machine.
Alerts
Alerting on every error quickly becomes noise. A practical set of rules:
- about a new error that hasn’t happened before;
- about a sharp rise in the frequency of a known error;
- about a regression — an error marked as fixed that reappears.
Channels — email, messengers, webhooks. The principles are the same as for infrastructure alerts: notify only about things that require action.
Personal data in events
An error event easily carries personal data: an email address in query parameters, IP address, form contents. For a Russian company this is an issue not only of security but of law: since July 1, 2025 primary recording of personal data of Russian citizens must be kept in databases on Russian territory (details — in the article about 152-FZ). Sending events containing such data to a foreign cloud contradicts this requirement.
What to do:
- do not enable sending personal data by default (
send_default_piiin Python and the analogous setting in JavaScript should remain off); - scrub sensitive fields before sending in the
beforeSend/before_sendhandler; - enable server-side data scrubbing in the project settings;
- if data in events is unavoidable — host GlitchTip or Sentry on your own server in Russia.
Common mistakes
- Sampling 100% of traces in production — the quota runs out and the extra data is useless.
- No source maps — frontend stack traces are unreadable.
- Release version not passed — it’s unclear whether the error is fixed.
- DSN with write permissions checked into a public repo of server code. The frontend DSN is public by design, but server-side DSNs are better passed via environment variables.
- Alerting on every event — after a week they stop being read.
- Personal data is sent to a foreign cloud along with the stack trace.
// Similar task
If you are dealing with something similar
This article belongs to one of the main working topics. You can keep reading on the topic, go to the homepage to understand what I do, or open the service pages directly.
Article topic
Deploy and reliability
Docker, CI/CD, releases, monitoring, observability, and incident handling.
Typical tasks behind this topic
- Set up deployment without manual chaos
- Add monitoring, alerts, and baseline observability
- Investigate incidents and stabilize production
// Next step
If you need help with this topic, not just another article, it is better to go straight to the service page. The homepage and topic collection stay available as secondary routes.
Open services// Reviews
Related reviews
I came with an expensive request to configure a VPS server, but during the consultation Mikhail suggested a much simpler, more affordable solution. In the end I saved time and money. Mikhail — a true expert who works for the client's result, not for the fee. I recommend him!
I came with an expensive request to configure a VPS server, but during the consultation Mikhail suggested a much simpler and more cost-effective solution. In the end I saved budget and time. Mikhail — a true expert who …
VPS setup, server setup
2026-05-12 · ★ 5/5
Excellent work! Set up the server very quickly, installed the control panel, and configured the IP. Definitely recommend!
Excellent work! Very quickly set up the server, installed the panel, configured the IP I can definitely recommend it!
Everything was excellent; helped promptly and professionally. Thank you — I recommend them to the community.
Everything's great, helped promptly and professionally, thank you, I recommend it to the community
VPS setup, server setup
2026-04-16 · ★ 5/5
There were several issues concerning both the technical side and overall understanding. Mikhail responded quickly, resolved the technical problems, and helped me understand them — many thanks. I'm satisfied with the result.
There were several issues concerning both the technical side and overall understanding. Mikhail responded quickly to the request, helped sort things out and resolved the technical problems and helped clarify …
VPS setup, server setup
2026-02-18 · ★ 5/5
Everything was done quickly and efficiently. I recommend.
Everything was done quickly and efficiently. I recommend.
VPS setup, server setup
2026-01-17 · ★ 5/5
Everything went well; the contractor responded quickly to questions and helped resolve the issue. Thanks!
Everything went well, the contractor responded quickly to questions and helped resolve the issue. Thank you!
VPS setup, server setup
2025-12-16 · ★ 5/5
// Contact
Need help?
Get in touch with me and I'll help solve the problem
I reply within one business day (03:00-13:00 GMT)
Или оставьте заявку здесь:
// Related