# swaggo/swag

> Generates Swagger 2.0 API documentation from annotations in Go code

Navigation: [Developer Tools](category/developer-tools.txt) · [Index](../llms.txt)

## Facts

- GitHub: https://github.com/swaggo/swag
- HTML: https://awesomeopensource.dev/project/swaggo-swag
- License: MIT
- Language: Go
- stars: 13054
- Topics: annotations, golang, openapi, swagger, swagger2
- Activity score: 3.8/5 (Active)
- Last commit (any branch): 2026-09-30
- Last release: v2.0.0-rc6 2026-09-13

## Description

Swag reads declarative comments above Go handlers and structs and emits a Swagger 2.0 specification, so an existing API gets browsable documentation without a separate schema file. It ships plugins for popular Go web frameworks, supports security definitions, model composition and custom types, and generates the docs package that Swagger UI serves. The tool is written in Go and runs as a CLI in the build pipeline.

## Maintenance activity

- Recency: 71% (weight 40%) — last commit: 44 days ago
- Commit volume: 63% (weight 25%)
- Releases: 68% (weight 25%) — last release: 61 days ago
- Bug fixes: 100% (weight 10%)
- Commits: 5 / 90d, 25 / 365d

## Screenshots

- [Screenshot of the Swagger UI showing the Swagger Example API endpoints and request details](https://awesomeopensource.dev/uploads/1752/f1359105d83254a6.png)

## Similar projects

- [stablyai/orca](stablyai-orca.md): Run several coding agents in parallel, each in its own Git worktree · Activity score 5.0/5 (Thriving)
- [tauri-apps/tauri](tauri-apps-tauri.md): Build small desktop and mobile apps with a web frontend and a Rust core · Activity score 5.0/5 (Thriving)
- [microsoft/terminal](microsoft-terminal.md): Tabs, panes and GPU rendering for PowerShell, cmd, WSL and SSH on Windows · Activity score 5.0/5 (Thriving)
- [ant-design/ant-design](ant-design-ant-design.md): A UI Design Language. · Activity score 5.0/5 (Thriving)
- [microsoft/playwright](microsoft-playwright.md): End-to-end testing and browser automation across Chromium, Firefox and WebKit · Activity score 5.0/5 (Thriving)
- [nvm-sh/nvm](nvm-sh-nvm.md): POSIX shell script for installing and switching between Node.js versions · Activity score 5.0/5 (Thriving)
