AWS Launches Blocks, an Open-Source TypeScript Framework Designed for AI Agents to Build Backends AWS launched Blocks, an open-source TypeScript framework in public preview, designed for AI agents to build backends with local-first development and zero-infrastructure-code deployment to AWS services. The framework bundles application code, local mocks, and production infrastructure, allowing developers to run full-stack apps locally without an AWS account and deploy to Lambda, DynamoDB, and Bedrock unchanged. Blocks positions itself as a 2026-era framework that guides AI agents to write correct, production-ready code by default, differentiating from Amplify by focusing on type-safe infrastructure-from-code and AI-agent-first design. AWS recently released AWS Blocks https://docs.aws.amazon.com/blocks/latest/devguide/what-is-blocks.html in public preview, an open-source TypeScript framework in which each "Block" bundles application code, a local development implementation, and the AWS infrastructure required to run it in production. Developers can use npm run dev and get a working application with Postgres, authentication, real-time messaging, and file storage on their machine. Moreover, they do not need an AWS account. When they deploy, the same code runs on Lambda, DynamoDB, Aurora, API Gateway, and Bedrock with zero changes. The announcement https://aws.amazon.com/about-aws/whats-new/2026/06/aws-blocks-preview/ describes it as removing "t he need to learn infrastructure tools ." What sets Blocks apart from the crowded backend-framework landscape is a design premise firmly rooted in 2026: AI agents write code, and the framework provides the correct way to write it from the start. Blocks ships with built-in steering files that guide coding agents toward correct architecture without custom configuration. A developer can prompt an agent to "add authentication and a database," and the agent produces code that works locally and deploys to production-grade AWS services because the framework constrains the agent to follow correct patterns. The composability model is straightforward. Each Block is an npm package covering one backend capability: database tables, user authentication, AI agents, file uploads, background jobs, scheduled tasks, real-time notifications, and email. Developers import the Blocks they need, compose them, and the framework generates AWS infrastructure following best practices. Furthermore, type safety flows from the data schema to the frontend without a code-generation step, covering web frameworks Next.js, Nuxt, Astro, React, Vue, Svelte, Angular and native clients Swift, Kotlin, Dart/Flutter from a single backend definition. The local-first development model is the most developer-friendly aspect. Blocks uses Node.js conditional exports to load different implementations per context. The same new KVStore scope, 'todos' line becomes an in-memory store during local development, a DynamoDB table at deployment time, and an SDK call in the Lambda runtime. Hot reload restarts the backend on every save with sub-second feedback. DevelopersIO tested https://dev.classmethod.jp/en/articles/20260620-aws-blocks-preview/ the full end-to-end flow from local startup through deployment to AWS sandbox and confirmed that writes to real Aurora and DynamoDB resources worked without code changes. The CDK escape hatch prevents this from becoming another opinionated walled garden. Blocks applications are CDK applications, and any CDK construct works alongside Blocks, and teams can embed Blocks into existing CDK stacks. When the built-in Blocks don't cover a use case, developers can drop into CDK for direct resource configuration. Custom Blocks can package infrastructure, runtime logic, and local mocks into reusable modules shared across projects. The Amplify question is the elephant in the room. A detailed DEV Community analysis https://dev.to/aws-builders/what-is-aws-blocks-how-it-differs-from-amplify-and-app-studio-and-what-each-one-is-aiming-for-2kn0 laid out the overlap directly: Amplify Gen 2 also defines backends code-first in TypeScript, on top of CDK. Blocks' infrastructure-from-code layer and Amplify Gen2's backend definition are both a 'write your backend in TypeScript' experience standing on CDK, so they sit close in philosophy. AWS positions them as complementary: Amplify provides hosting, CI/CD, and a managed backend experience, while Blocks focuses on type-safe infrastructure-from-code with local-first development. The same analysis noted the distinctive 2026 premise: It takes for granted that AI agents write code, and the framework itself carries the correct way to write from the start. This is a design that lowers not only the cost of humans learning but the cost of agents making mistakes. At preview, approximately 20 Blocks are available https://docs.aws.amazon.com/blocks/latest/devguide/building-blocks-reference.html covering databases Postgres via Aurora, DynamoDB , authentication Cognito , AI agents and knowledge bases Bedrock , file storage S3 , real-time messaging, background jobs, scheduled tasks, and email SES . There is no additional charge for Blocks itself. Teams pay only for the underlying AWS services their application consumes. Early preview caveats from DevelopersIO's testing https://dev.classmethod.jp/en/articles/20260620-aws-blocks-preview/ : Block constructor signatures may change between preview releases pin your versions , local data persistence depends on mock implementations verify against real AWS resources for production accuracy , and the framework currently requires Node.js 22 or later. AWS Blocks is available now in public preview https://aws.amazon.com/about-aws/whats-new/2026/06/aws-blocks-preview/ across all commercial AWS regions. The source code https://github.com/aws-devtools-labs/aws-blocks is on GitHub under the Apache 2.0 license.