Mastra
Mastra is a San Francisco-based developer infrastructure company founded in 2024 that provides an open-source Apache 2.0 TypeScript framework plus a cloud platform for building, observing, and deploying AI agents, serving enterprise customers including Replit, Sanity, SoftBank, MongoDB, and Salesforce.
- Company typePrivate
- Founded2024
- HeadquartersSan Francisco, United States
- Headcount51–100
- GTM typeB2B
- OfferingSoftware
What Mastra does
Mastra is a privately held developer infrastructure company founded in 2024 in San Francisco that provides a TypeScript-native open-source framework for building AI-powered applications and agents. The core framework is distributed under an Apache 2.0 license and runs on Node.js with support for Bun, Deno, and Cloudflare Workers. The platform bundles five integrated modules: a Framework for defining typed agents, workflows, and tools; Observability for metrics, logs, traces, anomaly detection, and LLM-as-Judge scoring; Studio for collaborative testing, visual editing, and dataset management; Server for one-command cloud deployment exposing agents as REST endpoints; and Memory Gateway, which routes 300+ models from 90+ providers and adds Observational Memory technology scoring 94.87% on the LongMemEval benchmark with 5-40x conversation compression. The proprietary memory architecture enables 4-10x reductions in token costs via prompt caching and underpins enterprise-grade durability, permission systems, and human-in-the-loop workflows.
The company monetizes a three-tier platform subscription layered on top of the free open-source core: a free Starter tier (100K observability events, 24 CPU hours, 15-day retention), a $250/month Teams tier (1M events, 250 CPU hours, 6-month retention, SSO, SOC 2 docs), and custom Enterprise pricing (RBAC, audit logs, VPC deployment, dedicated support engineer, SLAs). Additional monetization includes usage-based overages on observability events ($8-10 per 100K), CPU time ($0.25-0.35/hr), data egress, memory tokens, and retrieval storage, plus managed LibSQL and Postgres database offerings and an annual Enterprise License for source-available self-hosted deployments. Go-to-market combines product-led growth via npm (1.8 million monthly downloads) with enterprise field sales targeting Fortune 500 design partners including Replit, Sanity, SoftBank, WorkOS, Factorial, Brex, MongoDB, Workday, Salesforce, Fireworks AI, Marsh, and Elastic.
The company was founded by Sam Bhagwat (CEO), Abhi Aiyer (CTO), and Shane Thomas (CPO), who previously built and sold the Gatsby framework to Netlify. Mastra has raised approximately $35 million to date across a $13M seed/early round in March 2025 led by Y Combinator and a $22M Series A in April 2026 led by Spark Capital. In June 2026, the company's npm ecosystem was targeted in a supply chain attack by North Korean state-sponsored hackers (Sapphire Sleet group) compromising 140+ packages, prompting incremental security investment including the May 2026 OpenBox AI runtime-governance partnership. Operations span the United States, Japan, and Spain with the platform positioned as connective tissue in the emerging MCP/A2A agent protocol stack.
Mastra firmographics
Firmographics- Name
- Mastra
- Website
- https://mastra.ai
- Company type
- Private
- Founded year
- 2024
- Operating status
- Operating
- Headcount range
- 51–100 employees
- Short description
- Mastra is a San Francisco-based developer infrastructure company founded in 2024 that provides an open-source Apache 2.0 TypeScript framework plus a cloud platform for building, observing, and deploying AI agents, serving enterprise customers including Replit, Sanity, SoftBank, MongoDB, and Salesforce.
- Ownership category
- akta.pro rank
Mastra industry classification
Industry- Product category
- AI Agent Development Platform
- NAICS
- Computer Systems Design and Related Services (54151), Computing Infrastructure Providers, Data Processing, Web Hosting, and Related Services (5182)
- SIC
- Services-Computer Programming Services (7371)
- akta.pro primary industry
- Managed Application Platforms (App PaaS & Runtime Services) (HDABAAAD)
- akta.pro secondary industry
- Low-Code/No-Code Application Platforms (HDAEAKAA)
Keywords
Where Mastra is headquartered
LocationHeadquarters
- HQ city
- San Francisco
- HQ country
- United States
- HQ region
- North America
Markets served
Mastra business model
Business model- GTM type
- B2B
- Offering type
- Software
- Cost components
- Personnel, Technology or R&D, Infrastructure, Marketing or Sales, Operations
Revenue model
- Platform Subscription Tiers: Three-tier subscription model: Starter (free) for observability events (100K), CPU hours (24), 15-day data retention; Teams ($250/month) for 1M observability events, 250 CPU hours, 6-month retention, multiple teams, SSO, SOC 2 docs; Enterprise (custom) for volume/retention, RBAC, audit logs, SLAs, dedicated support engineer.
- Compute and Storage Usage: Overage charges for observability events beyond tier limits ($8-10 per 100K), CPU time ($0.25-0.35/hr), data egress ($0.10/GB), memory token usage ($10/1M tokens after tier limits), retrieval storage ($20/GB after tier limits).
- Open Source Core (Freemium): Core framework is Apache 2.0 licensed and free. Enterprise features are source-available under Mastra Enterprise License. Platform provides monetization layer on top of free open source.
- Enterprise License: Self-hosted enterprise features including RBAC, SSO, IAM, network policy integration, VPC deployment, and flat annual fee without per-trace or per-seat metering.
- Managed Databases: LibSQL and Postgres managed database offerings with row limits, compute hours, and storage billing. LibSQL: 1M rows/month free, then $2-2.50/1M reads. Postgres: 5 hours compute free, then $0.40-0.50/hr.
Pricing tiers
| Model | Billing | Price |
|---|---|---|
| Subscription | Monthly | Free tier with observability, CPU hours, and 15-day data retention |
| Subscription | Monthly | $250/month for growing teams with enhanced limits and collaboration features |
| Subscription | Multi-year contract | Custom enterprise pricing with volume discounts and dedicated support |
| Freemium | Monthly | Free open source framework under Apache 2.0 license |
Go-to-market motion3 records
Distribution channels5 records
Marketing channels10 records
Mastra product offering
Product offeringCore offering
Mastra provides a TypeScript-native open-source framework and cloud platform for building, deploying, and observing AI agents and applications. The core offering bundles agents, workflows, memory, tools, and observability primitives into a single unified system with built-in support for 300+ AI models, MCP servers, and deployment to Vercel, Netlify, and Cloudflare. A managed cloud platform adds observability, compute, storage, RBAC, SSO, and enterprise governance on top of the free Apache 2.0 framework.
Product overview
Mastra is an AI agent platform comprising an open-source TypeScript framework (Apache 2.0 licensed) plus a cloud platform with five modules: Framework for building agents with memory, tools, and workflows; Observability for metrics, logs, and traces; Studio for collaborative testing and evaluation; Server for deployment; and Memory Gateway for unified model routing with 5-40x memory compression. The ecosystem includes starter Templates, an MCP Course, educational books (Principles and Patterns), Workshops, and the Agents Hour podcast. Notable customer-built products include Replit Agent 3, Sanity Content Agent, SoftBank's Satto Workspace, and Factorial One.
Differentiator
Problem solved
Functional benefit
Products and services
- Mastra Framework Open-source TypeScript framework for building AI-powered applications and agents with built-in primitives for agents, memory, tools, workflows, and observability. Distributed under Apache 2.0 license for free use.
- Mastra Observability AI observability platform delivering metrics dashboards, structured logs, and step-by-step traces for production agent runs with anomaly detection, cross-step correlation, and LLM-as-Judge quality scoring.
- Mastra Studio Collaborative workspace for testing agents, tracing execution, refining prompts, scoring outputs, and managing datasets and experiments without source code access.
- Mastra Server Cloud deployment platform for agents and workflows via a single deploy command, exposing agents as REST API endpoints with automatic routing, scaling, authentication via JWT/Clerk/Supabase/Firebase/Auth0/WorkOS, and stream data redaction.
- Memory Gateway AI gateway providing observational memory and unified model routing across 300+ models with transparent pricing and automatic failover.
- Mastra Templates Pre-built project templates (Deep Search, Browser Agent, Chat with Database, Chat with PDF, Slack Agent, GitHub PR Code Review, Docs Expert, Company Knowledge Agent, Autonomous Personal Assistant) for AI agent builders.
- Mastra 101 Course
Quantifiable outcome
- 94.87% on LongMemEval benchmark, outperforming RAG implementations
- +7 more outcomes
Companies that use Mastra
Customer profileNamed customers15 records
Segments5 records
Ideal customer profiles3 records
Mastra technology and API
TechnologyTechnology focussed Yes
API detail
- Has API
- Yes
- API docs
- API detail
Core technology
AI maturity
App detail
Integration24 records
AI capability15 records
Feature9 records
Mastra partnerships and signals
Strategic signalPartnerships
13 partnerships are on record, tiered flagship and core.
- OpenBox AIflagshipPartnership to make runtime governance a default feature for all Mastra TypeScript agents. Integration enables scoring, cryptographic attestation, and auditable logs via single function call. Addresses EU AI Act requirements (enforceable August 2, 2026) with 97% of enterprises expecting material AI-agent security incidents within 12 months. Generally available May 4, 2026. OpenBox AI announced $5M seed round alongside this partnership.
- InngestcoreInngest provides additional persistence layer for Mastra workflows, enabling durable execution. Used by Replit to boost workflow completion rates from 80% to 96%, ensuring workflows complete even if servers fail mid-execution.
- VercelcoreMastra includes built-in deployer for Vercel, one-click deployment option for Next.js and React projects using Mastra framework.
- NetlifycoreMastra includes built-in deployer for Netlify, enabling straightforward deployment of Mastra projects.
- CloudflarecoreMastra supports deployment to Cloudflare Workers and includes Cloudflare Durable Objects storage adapter. Integrates with Cloudflare's edge computing platform.
- PlaywrightcoreUsed by Replit Agent 3 for self-testing code, enabling 90% autonomy success rate. Playwright automation within Mastra agents enables self-healing code generation loops.
- CursorcoreMastra MCP server integrates with Cursor IDE. MCP Course supports Cursor, Windsurf, and VSCode. CLI Actions enable Cursor to test drive Mastra projects.
- WindsurfcoreMastra MCP Course supports Windsurf IDE alongside Cursor and VSCode, enabling AI-assisted Mastra development within the IDE.
- VSCodecoreMastra MCP Course supports VSCode alongside Cursor and Windsurf. MCP server installation available for VSCode environments.
- CopilotKitcoreCopilotKit's framework for building agentic applications with generative UIs integrates with Mastra. Factorial uses CopilotKit's useCoAgent for shared state between frontend and agent.
- TemporalcoreSanity uses Temporal for background task orchestration, computing schema graphs cached in Redis, and bulk operations on large datasets (some customers have 10M+ documents).
- BraintrustcoreFactorial uses Braintrust for AI tracing and built extensive evals for their One agent's performance monitoring.
- CargocoreWorkOS uses Cargo (enrichment provider) exposed as MCP server, connected to Mastra agents for lead enrichment and filtering.
Scale indicators23 records
Recent moves6 records
Expansion highlights6 records
Mastra competitors and assessment
Company assessmentDirect peers
- LangChain: Direct competitor offering a Python/JavaScript framework for building LLM-powered agents and applications. LangChain and Mastra both target AI developers with composable primitives, observability via LangSmith, and model-agnostic orchestration.
- CrewAI: Multi-agent orchestration framework focused on role-based agent collaboration. Competes with Mastra on multi-agent supervisor patterns and workflow automation for enterprise AI agent deployment.
- Microsoft AutoGen: Microsoft's open-source framework for multi-agent conversation and orchestration. Competes with Mastra's graph-based workflow engine and multi-agent supervisor patterns, with strong integration into Azure AI services.
- LlamaIndex: Framework for building LLM applications over proprietary data with RAG focus. Competes with Mastra's knowledge retrieval and RAG capabilities, including vector database support and document workflows.
- Semantic Kernel (Microsoft): Microsoft's SDK for integrating LLMs into .NET and Python applications with planning and memory capabilities. Competes with Mastra on agent orchestration, memory primitives, and enterprise integration patterns.
- Haystack (deepset): Open-source Python framework for production-ready LLM applications with pipelines, agents, and retrieval components. Competes with Mastra as a developer framework for building production agent systems, though focused on Python rather than TypeScript.
Emerging players
- Fixpoint (DSPy): Stanford-spawned framework for programmatic LLM pipeline optimization. Competes with Mastra's agent optimization and prompt engineering capabilities, particularly around systematic eval and tuning workflows.
- Vellum AI: Developer platform for LLM application development with prompt engineering, evaluation, and observability tools. Overlaps with Mastra Studio's visual editing, eval workflows, and observability module.
Broad incumbents
- Amazon Bedrock Agents: AWS-managed agent runtime offering integrated agent orchestration with foundation models. Competes as a broader incumbent platform where Mastra Cloud could be deployed, offering enterprises a tightly coupled alternative to Mastra's framework-agnostic approach.
- Google Vertex AI Agent Builder: Google's enterprise agent development platform with built-in orchestration and grounding. Competes with Mastra's full-stack agent framework, leveraging Google Cloud distribution and foundation model integration.
Market position
Strengths5 records
Weaknesses5 records
Competitive moat5 records
Key risks5 records
Key highlights7 records
Customer concentration
Mastra social profiles
Digital presenceMastra compliance and trust
Trust signalCompliance1 record
Mastra financial estimates
Financial estimateRevenue estimate
Valuation estimate
Mastra leadership team
Management profileNumber of profiles
Profiles5 records
Mastra funding detail
Funding detailFunding overview
Funding rounds3 records
Investors23 records
Funding detail is available on the Subscription and Enterprise plan.Contact sales →
Mastra M&A and investment
M&A and investmentM&A
Investments
M&A and investment is available on the Subscription and Enterprise plan.Contact sales →
Frequently asked questions about Mastra
What does Mastra do?
Mastra provides a TypeScript-native open-source framework and cloud platform for building, deploying, and observing AI agents and applications. The core offering bundles agents, workflows, memory, tools, and observability primitives into a single unified system with built-in support for 300+ AI models, MCP servers, and deployment to Vercel, Netlify, and Cloudflare. A managed cloud platform adds observability, compute, storage, RBAC, SSO, and enterprise governance on top of the free Apache 2.0 framework.
Is Mastra a public or private company?
Mastra is a private company. It is classified as venture growth investor backed and is currently operating.
When was Mastra founded?
Mastra was founded in 2024. It employs 51 to 100 people.
Where is Mastra based?
Mastra is headquartered in San Francisco, United States, in the North America region.
How does Mastra make money?
Five revenue lines are on record. Platform Subscription Tiers are the primary driver. The others are compute and Storage Usage, open Source Core (Freemium), enterprise License and managed Databases.
Who are Mastra's main competitors?
Direct peers on record are LangChain, CrewAI, Microsoft AutoGen, LlamaIndex, Semantic Kernel (Microsoft) and Haystack (deepset). Emerging players are Fixpoint (DSPy) and Vellum AI. Broad incumbents are Amazon Bedrock Agents and Google Vertex AI Agent Builder.
Does Mastra have an API?
Yes. Mastra Server exposes all registered agents and workflows as REST API endpoints. An OpenAPI specification is available at /api/openapi.json with interactive Swagger UI documentation at /swagger-ui. Authentication supported via JWT, Clerk, Supabase, Firebase, Auth0, and WorkOS. Stream data redaction is enabled by default. Developer documentation is at mastra.ai/docs/server/mastra-server.
What industry is Mastra in?
Mastra's product category is AI Agent Development Platform. Its primary akta.pro industry code is HDABAAAD, Managed Application Platforms (App PaaS & Runtime Services), with a secondary code of HDAEAKAA, Low-Code/No-Code Application Platforms. Its NAICS code is 54151 and its SIC code is 7371.