Google keeps pairing them: the searches "langchain vs mastra" and "mastra vs langchain" drew 110 impressions for this site in the last three months. The pairing flatters Mastra. On November 13, 2026, LangChain announced a $300 million Series C at a $3 billion valuation, led by CapitalG, taking its total raised to about $460 million. Mastra, the TypeScript challenger built by the team behind Gatsby, has raised $35 million in total. On money, reach and ecosystem, the winner is already clear. The open question is not whether Mastra catches LangChain. It is whether the model labs make both of them a feature.
The scoreboard
| Measure | LangChain | Mastra |
|---|---|---|
| GitHub stars | 146,312 | 28,033 |
| GitHub forks | 24,448 | 2,784 |
| Language | Python | TypeScript |
| License | MIT | Apache-2.0 core, enterprise parts commercial |
| Latest round | $300M Series C at a $3B valuation (Nov 2026) | $22M Series A (Apr 2026) |
| Total raised | About $460M | $35M |
| Adoption score in our directory | 100 | 96 |
Stars are from this site’s directory of 548 agent frameworks, checked in September 2026. LangChain has more than five times Mastra’s stars and nearly nine times its forks, and its stable widens the gap: LangGraph, its agent runtime, adds 41,626 stars of its own, so the company’s main repos hold about 217,000 stars between them. Mastra’s counter is real but narrower. It is the default TypeScript framework, it shipped its 1.0 in January 2026, and npm counted about 7.4 million downloads of its core package in the month to late October 2026. For a JavaScript team, that native fit is the whole argument, and our Python vs TypeScript comparison shows how much of this market now starts in TypeScript.
Open source keeps the revenue small
LangChain’s framework is MIT licensed and free, and the money shows it. TechCrunch put the company’s annualized recurring revenue at $12 to $16 million in mid 2025, against a valuation that has since reached $3 billion. That gap is the business model: the framework is the distribution, and the revenue sits in LangSmith, the paid platform for tracing, evaluating and deploying agents that sits around the free code. Mastra has the same shape, an Apache-2.0 core with a paid platform launched alongside its Series A. So the Series C is not a bet on framework revenue. It is a bet that whoever owns the layer above the code owns the market, and that open source is how you buy that layer’s adoption.
The threat is not Mastra. It is the labs.
The big AI companies have already launched their competitors; they are sitting in this directory. OpenAI’s Agents SDK holds 29,424 stars, which already puts it ahead of Mastra. Google’s ADK holds 21,531 stars in Python, with Go and Java editions behind it. Microsoft’s AutoGen, at 60,981 stars, is second only to LangChain itself in the chart above. A lab can bundle its SDK with its models, its cloud and its distribution, and charge the bundle once. The independents’ defense is neutrality: LangChain and Mastra run every model from every lab, while a lab’s SDK quietly prefers its own. The $300 million is, in the end, a bet that enterprises will keep insisting on that choice.
The verdict for builders is simpler. Take Mastra if your team is TypeScript and wants the framework that fits its stack natively. Take LangChain for the ecosystem, the integrations and the platform the Series C is funding. And watch OpenAI and Google, because the versus that decides this market is not LangChain vs Mastra. It is the independents against the labs.
Sources: LangChain on GitHub | Mastra on GitHub | LangChain Series C coverage | Mastra funding record