AI app stacks
Mara Lindqvist11 min read54 views

Promptfoo vs DeepEval vs Ragas: the TypeScript reality check for Next.js RAG apps (2026)

Promptfoo, DeepEval and Ragas are the three most-recommended open-source LLM evaluation frameworks. For a TypeScript team the first question is which of them you can actually run. We checked the registries in August 2026, and the usual answer is out of date.

A continuous-integration quality gate with three evaluation lanes, two passing and one halted, ShipGarden, 2026
A continuous-integration quality gate with three evaluation lanes, two passing and one halted, ShipGarden, 2026
On this page

The quick answer (2026)

If you are building a RAG feature into a Next.js app and you want automated evals in CI, the first question is not "which framework has the best metrics." It is "what language will my eval harness live in." That single question eliminates two of the three most-recommended tools for most TypeScript teams, and almost nobody writes it down.

  • Promptfoo logo
    Promptfoo is the only one of the three that is TypeScript-native end to end. It installs from npm, is configured in YAML, and runs as a CLI you can drop straight into a GitHub Actions step. MIT-licensed.
  • DeepEval logo
    DeepEval is Python-first with the deepest metric library of the three, and since February 2026 it also publishes a TypeScript SDK. That SDK is real, but it is early and carries roughly one percent of the Python package's download volume.
  • Ragas logo
    Ragas is Python-only, has the most rigorous RAG-specific metrics, and is also the slowest-moving of the three right now. Its last release on PyPI was January 2026, and the project has changed GitHub organisations.

We road-test these building blocks so we can own the stack that funds the life, not chase whichever framework is loudest this quarter. Here is what actually changes once you check the package registries instead of the landing pages.

At a glance (verified August 18, 2026)

Scroll to see more

ToolLanguageLatest releaseStarsWeekly downloadsLicense
Promptfoo PromptfooTypeScript (Node)npm promptfoo 0.122.024.3k456,903 (npm)MIT
DeepEval DeepEvalPython, plus a TypeScript SDKPyPI 4.1.8 (Aug 12, 2026), npm 0.9.1017.7k1,223,856 (PyPI) / 11,388 (npm)Apache-2.0
Ragas RagasPython onlyPyPI 0.4.3 (Jan 13, 2026)15.4k364,725 (PyPI)Apache-2.0

Star counts read from promptfoo/promptfoo, confident-ai/deepeval and vibrantlabsai/ragas on August 18, 2026. Download figures are the npm registry and PyPI download APIs for the week ending August 15, 2026. Every claim below links to its source.

The thing every comparison gets wrong in 2026

Search this matchup and you will find a dozen articles, most of them good, all of them written for a Python reader. The best-ranking three-way comparison we read describes the split as "Python team goes DeepEval, CLI or Node team goes Promptfoo." That was accurate when it was published in February 2026. It is now out of date in one specific, checkable way.

DeepEval ships a TypeScript SDK. The npm package deepeval was first published on February 22, 2026, and describes itself as "The LLM Evaluation Framework for TypeScript." It lives in the typescript/ directory of the same confident-ai/deepeval monorepo as the Python package. As of August 18, 2026 it is at version 0.9.10 across 14 published releases.

So the honest 2026 answer is not "DeepEval is Python-only." It is: DeepEval has a TypeScript SDK, and you should know exactly how young it is before you bet a CI gate on it.

Here is the number that tells you. In the week ending August 15, 2026, the Python deepeval package pulled 1,223,856 downloads. The npm deepeval package pulled 11,388. That is under one percent. The TypeScript SDK is also still pre-1.0, which by the project's own versioning convention means the API surface is not yet frozen.

That is not a reason to avoid it. It is a reason to pin the version, read the changelog before upgrading, and not be surprised when a metric you rely on is documented only in Python.

Promptfoo: the TypeScript-native option

Promptfoo Promptfoo is a TypeScript TypeScript project, MIT-licensed, and by a wide margin the most-downloaded of the three on npm at 456,903 downloads in the week ending August 15, 2026. You configure it in YAML rather than in code: you declare your prompts, your providers, your test cases and your assertions, then run npx promptfoo eval. It exits non-zero when assertions fail, which is all a CI gate actually needs.

The design consequence worth understanding: because the config is YAML and the runner is a CLI, Promptfoo does not need to import your application code. It calls a provider. That provider can be an OpenAI or Anthropic model directly, or it can be an HTTP endpoint, which means it can call your deployed Next.js route handler and evaluate the real thing rather than a reimplementation of it. For a RAG feature, evaluating the actual /api/chat route is usually what you want, because most RAG bugs live in retrieval and prompt assembly rather than in the model call.

One compatibility detail to check before you install. The published package metadata for promptfoo 0.122.0 declares an engine requirement of Node 22.22.0 or higher. If your Next.js app is pinned to Node 20 in CI, that is a real constraint. It is easy to work around, since the eval job does not have to run on the same Node version as your build job, but it will bite you if you assume one runner serves both.

Where Promptfoo loses. Its metric library is narrower than DeepEval's. If you want a long menu of research-derived scorers out of the box, you will be writing more custom assertions here than you would in Python. Promptfoo's centre of gravity is prompt regression testing and red-teaming, not RAG-specific measurement.

DeepEval: the deepest metric library, Python-first

DeepEval DeepEval is Apache-2.0 and, on the Python Python side, the most actively shipped project of the three. Version 4.1.8 landed on PyPI on August 12, 2026, six days before we checked, and three releases went out in the first two weeks of that month alone. That cadence matters more than a star count when you are deciding what to build a CI gate on.

Its signature move is running inside pytest. You write eval cases as test functions, assert against metric thresholds, and your existing test infrastructure fails the build when hallucination or relevance scores slip. If your team already has Python in CI, this is the lowest-friction option in the list, and its metric coverage across RAG, agents, safety and bias is the broadest of the three.

Where DeepEval loses for a Next.js team. Everything above describes the Python package. The TypeScript SDK is a different, much younger artefact, and the documentation ecosystem, the community answers and the tutorials you will find when you search are overwhelmingly Python. You can absolutely use the TypeScript SDK today. You should just go in knowing you are an early adopter of it rather than a member of the mainstream, and that the pytest integration, which is the framework's best feature, has no TypeScript equivalent.

Ragas: the RAG specialist, and a release-cadence caveat

Ragas Ragas is Apache-2.0, Python-only, and the most academically grounded of the three on retrieval quality specifically. Its metrics, faithfulness, context precision, context recall and answer relevancy, decompose a RAG answer into parts you can act on. Faithfulness tells you the generator is inventing things. Context recall tells you the retriever never surfaced the right chunk. Those are different bugs with different fixes, and Ragas is the tool that most clearly separates them.

Two facts to check before you adopt it in 2026. First, the project now lives at vibrantlabsai/ragas; the widely-cited explodinggradients/ragas path redirects there, and the PyPI project links point at the new organisation. Older tutorials and bookmarks still reference the old path.

Second, and more practically, its release cadence has slowed noticeably. The latest version on PyPI is 0.4.3, published on January 13, 2026. The two releases before it were December 23 and December 10, 2025. Compare that to DeepEval shipping three releases in a fortnight this month.

We want to be fair about what that does and does not mean. A stable, mature library does not need weekly releases, and Ragas still pulled 364,725 downloads in the week ending August 15, 2026, so it is in heavy production use. But a seven-month gap in an area moving as fast as LLM evaluation is a thing to weigh consciously, not to discover after you have wired it into a release gate. Check the repository's recent activity yourself before committing.

There is no JavaScript distribution of Ragas at all. The npm registry returns a 404 for the name. For a TypeScript team, using Ragas means running Python.

The Next.js pattern nobody writes down

Here is the practical resolution, and it is the part these comparisons skip because they are not written for app developers: your evals do not have to live inside your Next.js application.

Treat the eval harness as a separate CI concern that talks to your app over HTTP. Your Next.js route handler exposes the RAG endpoint. Your eval job, in whatever language, posts test inputs to a preview deployment of that endpoint and scores the responses. Nothing about that requires the eval framework and the app to share a runtime, a package manager, or a language.

Once you frame it that way, three sensible configurations fall out:

  1. All TypeScript. Promptfoo, YAML config, HTTP provider pointed at your preview deployment. One language, one lockfile, no Python in the repo. This is the default we would reach for on a
    Next.js
    Next.js codebase with no existing Python.
  2. TypeScript app, Python eval sidecar. A small evals/ directory with its own pyproject.toml, running DeepEval or Ragas in a separate CI job. You accept a second toolchain in exchange for the best metric coverage available. Reach for this when retrieval quality is the product and you need Ragas-grade decomposition.
  3. Both. Promptfoo for fast prompt-regression checks on every pull request, plus a heavier Python RAG-quality suite on a nightly schedule. This is a common shape once a team has been burned once by each failure mode.

The mistake we would steer you away from is picking the framework first and then contorting your repository around it. Pick the CI shape you can maintain, then pick the framework that fits it.

Two TypeScript-native options the comparisons miss

If configuration-as-YAML is not to your taste and you want evals written in TypeScript as code, the three-way matchup is not the whole field.

  • Vitest
    Evalite is a TypeScript-native eval runner built on Vitest, describing itself as needing no API key to get started. At 185,276 npm downloads in the week ending August 15, 2026 it has meaningful adoption. If your team already writes Vitest tests, evals become just another test file, which is roughly what DeepEval's pytest integration gives Python teams.
  • Autoevals is an MIT-licensed scorer library rather than a full runner. It gives you the metric implementations and lets you call them from whatever harness you already have. Useful when you want DeepEval-style scorers inside an existing Vitest or Jest suite.

Neither replaces Ragas for deep retrieval analysis. Both are worth knowing before you conclude that a TypeScript team has to run Python to evaluate anything.

How we would choose

  • Next.js app, no Python in the repo, want a CI gate this week. Promptfoo. Check your Node version first.
  • Evals as TypeScript code rather than YAML, already on Vitest. Evalite, or Autoevals inside your existing suite.
  • Retrieval quality is the product and you need to know whether the retriever or the generator is at fault. Ragas, in a Python sidecar, after you have checked its current repository activity.
  • Python already in CI, want the broadest metric coverage and pytest gates. DeepEval.
  • TypeScript team specifically wanting DeepEval's metrics. The TypeScript SDK is real. Pin the version, and know you are early.

The honest summary is that there is no single winner, and any article claiming one is compressing a language decision, a CI decision and a metrics decision into a single ranking. Answer the language question first. The rest gets much simpler.

Sources

If you are still choosing the retrieval layer underneath all of this, our Postgres vector database walkthrough for Next.js RAG covers the pgvector path. And note that evaluation is a different job from production tracing: if what you actually need is to watch live requests rather than gate a build, start with our LLM observability comparison instead.

Mara Lindqvist

Written by

Mara Lindqvist

Mara Lindqvist curates the ShipGarden gallery, where we test open-source building blocks so we can own the stack that funds the life.

Frequently asked questions

Does DeepEval work with TypeScript?

Yes. DeepEval publishes a TypeScript SDK as the npm package deepeval, first released on February 22, 2026 and at version 0.9.10 as of August 18, 2026. It lives in the typescript directory of the confident-ai/deepeval monorepo. It is genuine but early: in the week ending August 15, 2026 it recorded 11,388 npm downloads against 1,223,856 for the Python package on PyPI, and it is still pre-1.0, so pin the version before relying on it in CI.

Can I use Ragas from JavaScript or TypeScript?

No. Ragas is Python-only and has no JavaScript distribution; the npm registry returns a 404 for the package name as of August 2026. If you want Ragas-grade retrieval metrics in a TypeScript project, run it as a separate Python job in CI that calls your deployed API over HTTP rather than importing your application code.

Which LLM evaluation framework is best for a Next.js app?

For a Next.js codebase with no existing Python, Promptfoo is the most practical starting point: it installs from npm, is configured in YAML, runs as a CLI that exits non-zero on failure, and can point an HTTP provider at your deployed route handler. Check the Node version first, since promptfoo 0.122.0 declares an engine requirement of Node 22.22.0 or higher. If retrieval quality is the core of your product, add Ragas or DeepEval in a Python sidecar job.

Is Ragas still maintained in 2026?

It is in heavy production use, with 364,725 PyPI downloads in the week ending August 15, 2026, but its release cadence has slowed: the latest version is 0.4.3, published on January 13, 2026. The project has also moved to the vibrantlabsai GitHub organisation, so older tutorials pointing at explodinggradients are out of date. Check the repository's current activity yourself before wiring it into a release gate.

Do my LLM evals have to run inside my Next.js app?

No, and treating them as separate is usually simpler. Run the eval harness as its own CI job that posts test inputs to a preview deployment of your API route and scores the responses over HTTP. Nothing then requires the eval framework and the application to share a runtime, a package manager or a language, which is what makes a Python eval sidecar alongside a TypeScript app a reasonable choice.

What is the difference between LLM evaluation and LLM observability?

Evaluation scores outputs against test cases before you ship, so it belongs in CI as a gate that can fail a build. Observability traces real requests after you ship, so it belongs in production as instrumentation. Promptfoo, DeepEval and Ragas are evaluation tools; platforms like LangSmith, Langfuse and Helicone are observability tools. Most teams that ship LLM features end up running one of each.