End-to-end typesafe APIs made easy
Import type only imports declarations to be used for type annotations and declarations. It always gets fully erased, so thereβs no remnant of it at runtime.
tRPC allows you to easily build & consume fully typesafe APIs, without schemas or code generation.
- π§ββοΈΒ Full static typesafety & autocompletion on the client - on inputs, outputs, & errors.
- πΒ Snappy DX. No code generation, run-time bloat, or build pipeline.
- πΒ Light. tRPC has zero deps and a tiny client-side footprint.
- π»Β Easy to add to your existing brownfield project.
- πΒ Batteries included. React-library + Next.js/Express adapters. (But tRPC is not tied to React - reach out if you want to make a Svelte/Vue/... lib)
- π₯Β Simple to use APIs for queries, mutations, & subscriptions support.
- β‘οΈΒ Request batching - requests made at the same time can be automatically combined into one
... and:
- πΒ Quite a few examples in the ./examples-folder
- β Β It's well-tested & running in production.
Still reading? Follow @alexdotjs on Twitter if you have any questions or want to keep up to date what's coming next.
π See full documentation documentation on tRPC.io. π
Quick start with a full-stack Next.js example:
npx create-next-app --example https://github.com/trpc/trpc --example-path examples/next-prisma-starter trpc-prisma-starter
Alex / KATT |
π Hi, I'm Alex and I am the main maintainer if tRPC, don't hesitate to contact me on Twitter or email if you are curious about tRPC in any way.
If you like working with tRPC, consider giving a token a apprecation by GitHub Sponsors or get in touch if you want your company's logo featured in the tRPC repository or on the website.
![]() |
Anthony Short |
Hampus Kraft |
Daniel Yogel |
Sam Holmes |
Jan Zimmek |
tRPC is developed by KATT, originally based on a proof-of-concept by colinhacks.