← All projects
Developer building blocks

Mastra

A TypeScript toolkit for building AI apps and agents, from first prototype to finished product.

What it does

Mastra gives JavaScript and TypeScript programmers the pieces to build AI-powered apps. It connects to many AI providers through one interface.

You can build agents that decide which tools to use, or step-by-step workflows when you want tight control. Agents and workflows can pause and wait for a person's approval, remember past conversations, and pull in data from files or databases.

It also includes testing ("evals") and monitoring tools, and a local studio screen for trying out agents.

Who it's for

Web developers who want to add AI agents or chat features to their apps.

Can I use it without coding?

Developers only. Set up with an npm command and used by writing code. New to this? Start here.

Can I run it?

Cost
Free, with optional paid extrasThe open-source version is free; the makers also sell a hosted or pro version.
Runs on
Server
Privacy
Sends what you give it to an online service
API key
Needed. An API key is a password-like code from an online AI service. What's that?

Try it

Using Claude Code, Cursor or another AI coding assistant? Paste the prompt and it will walk you through the setup.New to this?

Before you install

  • Only download from the official GitHub page. Copies with similar names exist for many popular projects.
  • No standard license listed. Check the GitHub page before using it for business.
  • Keep your API key private. Never paste it into websites or share it, and set a spending limit with the AI service.
  • What you type or upload is sent to an online service. Avoid sharing private or sensitive information.
  • More on staying safe

Where people are talking about it