Details
Category: HTTP Routers & Frameworks
Github: https://github.com/labstack/echo
Website: https://echo.labstack.com/
Published: May 2025
Tool Description
Echo
High performance, extensible, minimalist Go web framework.
Help and questions: Github Discussions
Benchmarks
Date: 2020/11/11 Source: https://github.com/vishr/web-framework-benchmark Lower is better!
The benchmarks above were run on an Intel(R) Core(TM) i7-6820HQ CPU @ 2.70GHz
Guide
Installation
// go get github.com/labstack/echo/{version}
go get github.com/labstack/echo/v4
Latest version of Echo supports last four Go major releases and might work with older versions.
Example
package main
import (
"github.com/labstack/echo/v4"
"github.com/labstack/echo/v4/middleware"
"log/slog"
"net/http"
)
func main() {
// Echo instance
e := echo.New()
// Middleware
e.Use(middleware.Logger())
e.Use(middleware.Recover())
// Routes
e.GET("/", hello)
// Start server
if err := e.Start(":8080"); err != nil && !errors.Is(err, http.ErrServerClosed) {
slog.Error("failed to start server", "error", err)
}
}
// Handler
func hello(c echo.Context) error {
return c.String(http.StatusOK, "Hello, World!")
}