# go-runewidth

> wcwidth for Go: the display width of characters and strings

Source: https://talira.ai/catalog/go-runewidth-t8aegt30
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library
- Categories: [libraries / text / strings](https://talira.ai/categories/libraries/text/strings), [languages / go](https://talira.ai/categories/languages/go)
- Licence: MIT[^1]
- Pricing: Free and open source[^1]
- Free tier: yes[^1]
- Backed by: [Yasuhiro Matsumoto](https://talira.ai/orgs/yasuhiro-matsumoto.md)

go-runewidth is a Go library, a wcwidth equivalent, that returns how many terminal cells a character or string takes, so text with East Asian wide characters and emoji lines up. It has an East Asian width mode for CJK locales, in which ambiguous Latin letters still count as one cell. It's by Yasuhiro Matsumoto (mattn).

## Links

- GitHub: https://github.com/mattn/go-runewidth
- Docs: https://pkg.go.dev/github.com/mattn/go-runewidth

## Problems it solves

- align CJK text in a Go terminal UI
- measure the column width of a string in Go
- pad table columns with emoji correctly in Go

## Features

- display width of runes and strings
- East Asian width mode for CJK locales
- wcwidth equivalent for Go

## Trust

Overall: 0.55 out of 1.
Signals: maintenance 0.89, adoption 0.57, momentum 0.22, community 0.60, backing 0.30, extensibility 0.00.

- last commit 13 days ago
- 44 commits in the last 90 days
- 728 GitHub stars
- 31 contributors
- accepts sponsorship (Github)
- backed by Yasuhiro Matsumoto

## Sources

[^1]: https://github.com/mattn/go-runewidth/blob/master/LICENSE (checked 29 Nov 2026)
