Comparison

Kolega vs Semgrep

Semgrep is a serious tool. It's open source, transparent, fast, has 20,000+ Pro rules, and a community of engineers writing custom rules for their own codebases. Most teams shortlisting a real SAST product end up comparing it to Semgrep at some point.

We did too.

On the RealVuln benchmark — an open-source test of 676 real vulnerabilities across 26 production repositories — Kolega scores 92.4%. Semgrep scores 17.5%. That's the same code, scored the same way, with the benchmark published in full.

This page explains the technical reason for the gap, where Semgrep is still the better choice, and how to decide between them.

View the full RealVuln benchmark

The headline numbers

MetricKolegaSemgrep
RealVuln F3 score92.4%17.5%
Rank (of 21 systems tested)#1#19
ApproachDeep semantic analysisPattern matching with cross-file taint analysis
Free tier1 app, 250k LOC, scheduled scans10 contributors, 50 repos, OSS rules
Starting paid priceFrom $39/mo$30–40 per contributor/mo

The technical difference

This is the comparison most worth understanding properly because the two tools look superficially similar (both do “SAST”) but work very differently underneath.

Semgrep is pattern matching. You write (or use community-written) rules that describe what a vulnerability looks like, and Semgrep finds matches in your code. Semgrep Pro added cross-file taint analysis, which extends pattern matching across function boundaries. This is genuinely useful and faster than most semantic analyzers.

The strength of this approach: it's transparent, fast, and you can write custom rules in a syntax that looks like the code you're trying to match. The community contributes rules constantly, so coverage of known vulnerability patterns is broad and updated.

The limitation: it can only find what someone's written a rule for. If a bug doesn't match an existing pattern — because it's a semantic flaw, a business logic error, a race condition, or a BOLA where the auth check is present but the query doesn't filter by the authenticated user — Semgrep won't catch it. There's no rule to match because the bug isn't shaped like a rule.

Kolega is semantic analysis. Rather than pattern matching, Kolega reads the data flow across your entire codebase, understanding what the code is trying to do, where data comes from, what touches it, and what the security implications are. There's no rule database to maintain because the engine reasons about the code directly.

The strength: it catches bugs nobody has written a rule for, including the ones that don't have known patterns yet. This is what produces the RealVuln gap.

The limitation: it's slower than pattern matching on first scan (though incremental scans are fast), and it's not open source.

Feature comparison

FeatureKolegaSemgrep
Pattern-based SAST
Custom rules in your codebaseComing soon
Cross-file taint analysisYes (Pro)
Semantic / data flow analysisYes (engine-level)Limited
BOLA detectionLimited
Race condition detection
Logic flaw detection
AI-generated code coverageLimited
Autofix PRs with testsLimited
Open source engineYes (CE)
Self-hostedEnterprise tier
IDE pluginsComing soon
Language coverage12 languages30+ languages
Ephemeral scanningN/A (self-hosted)
Free tier1 app, 250k LOC10 contributors, 50 repos
Starting paid priceFrom $39/mo$30–40 per contributor/mo

When to pick Semgrep

If your team has engineers who want to write and own custom rules for your specific codebase, Semgrep is built for that and Kolega isn't (yet). The ability to write a rule that catches a pattern your team specifically cares about is genuinely valuable.

If you need self-hosted on-prem with no external dependencies, Semgrep Community Edition runs entirely local. Our self-hosted runners exist but only on Enterprise.

If you need language coverage Kolega doesn't have yet — Semgrep supports 30+ languages, we support 12 of the most common ones — Semgrep wins by default.

If you want a tool whose engine you can audit, the Semgrep CLI is open source under LGPL-2.1. Some security teams require that and it's a legitimate requirement.

If you're an early-stage team that fits inside Semgrep's free tier (10 contributors, 50 repos), the free tier is genuinely useful and we're not going to pretend otherwise.

When to pick Kolega

If your priority is catching the vulnerabilities that don't match known patterns — logic flaws, BOLA, race conditions, semantic bugs — Kolega is built specifically for that category. The RealVuln gap (92.4% vs 17.5%) is what this looks like in practice.

If your codebase is increasingly AI-generated and you've noticed pattern-matching SAST is missing the bugs that ship, semantic analysis catches a different class of defect entirely.

If you want autofix PRs that include regression tests proving the fix works, our PR generation is built around that workflow.

If you don't want to maintain a custom rule library, Kolega doesn't require one. The engine reasons about your code without rules.

When to run both

This is more reasonable than it sounds. Semgrep is good at catching pattern-matchable bugs fast, and the custom rules let your team enforce specific organisational standards. Kolega catches the semantic flaws Semgrep can't.

A common stack: Semgrep in CI for fast pattern checks and custom rule enforcement, Kolega on PR open for deep semantic analysis. They don't overlap meaningfully — different engines, different bug classes.

FAQ

Why is Semgrep on RealVuln so far behind Kolega?

RealVuln tests real production vulnerabilities, many of which are semantic in nature (BOLA, broken auth flows, race conditions, second-order injection). Pattern matching is a powerful tool but it doesn't try to solve the semantic-analysis problem. Semgrep scoring 17.5% isn't a failure — it's evidence that the benchmark measures something different from what Semgrep was designed to optimise for.

We respect the Semgrep team enormously. The benchmark exists to make detection depth comparable, and we publish every result.

Can I just write Semgrep rules to catch the bugs Kolega catches?

In principle, yes. In practice, semantic vulnerabilities are hard to express as patterns. The auth-check-present-but-query-doesn't-filter-by-user bug requires understanding what the query does and what the auth check verifies — neither of which Semgrep's pattern engine reasons about. You can write rules that approximate the pattern, but they'll either miss the bug or fire constantly.

Is Kolega ever going to support custom rules?

Yes, it's on the roadmap. Not as the primary detection mechanism, but as a way for teams to encode organisational policies that the engine should enforce on top of its semantic analysis.

Why isn't Kolega open source?

The engine is proprietary because the IP is the engine. We've made the benchmark open source instead — you can independently verify detection depth without having to trust us.

Does Kolega store my code?

Code is cloned into ephemeral containers for the scan and deleted immediately after. Self-hosted runners are available on Enterprise for teams that need code to never leave their infrastructure.

See the benchmark for yourself

The benchmark is open source. The numbers are reproducible. If you're shortlisting SAST tools, the most useful thing you can do is run your own evaluation against the same data.

Scan a repo free

No credit card required. 7-day Pro trial. Drops to a free tier afterwards.