Build Microservices in Go

A pluggable framework for distributed systems with built-in service discovery, RPC, pub/sub, and AI agent integration.

go get go-micro.dev/v5
Go Micro microservices architecture

Everything You Need

Sane defaults out of the box. Every abstraction is swappable.

Service Discovery

Automatic registration and name resolution via mDNS, Consul, or etcd.

RPC Client/Server

Request/response and bidirectional streaming with load balancing built in.

Pub/Sub Events

Async messaging with NATS, RabbitMQ, or the built-in HTTP broker.

Data Model

Typed CRUD and queries backed by memory, SQLite, or Postgres.

gRPC Native

Use gRPC transport with any standard gRPC client. No lock-in.

MCP & AI Agents

Every service is automatically an AI-callable tool via Model Context Protocol.

Pluggable Architecture

Services connect through a registry for discovery and a broker for events. Swap any component without changing your service code — go from mDNS to Consul, or HTTP to gRPC, with a single option.

Go Micro architecture diagram
AI agent calling microservices via MCP

AI-Native by Default

Every service you build is automatically discoverable by AI agents via the Model Context Protocol. Add doc comments to your handlers and they become tool descriptions. No extra code, no configuration.

// SayHello greets a person by name.
// @example {"name": "Alice"}
func (g *Greeter) SayHello(ctx, req, rsp) error {
    rsp.Message = "Hello " + req.Name
    return nil
}

Developer Experience

micro run starts your services with hot reload, an API gateway, and an agent playground. micro chat lets you talk to your services through any LLM. micro new --template crud scaffolds a production-ready service in seconds.

Terminal showing micro run and micro chat

Trusted by Developers

23,000+ stars on GitHub. Production-ready. Apache 2.0 licensed.