GitPedia

Msgpack

msgpack.org[Go] MessagePack encoding for Golang

From vmihailenco·Updated June 17, 2026·View on GitHub·

> msgpack is brought to you by :star: [**uptrace/uptrace**](https://github.com/uptrace/uptrace). > Uptrace is an [open source APM](https://uptrace.dev/get/open-source-apm.html) and blazingly fast > [distributed tracing tool](https://get.uptrace.dev/compare/distributed-tracing-tools.html) powered > by OpenTelemetry and ClickHouse. Give it a star as well! The project is written primarily in Go, distributed under the BSD 2-Clause "Simplified" License license, first published in 2012. It has gained significant community traction with 2,654 stars and 251 forks on GitHub. Key topics include: encoding, go, golang, msgpack, serialization.

Latest release: v5.4.1
October 26, 2023View Changelog →

MessagePack encoding for Golang

Build Status
PkgGoDev
Documentation
Chat

msgpack is brought to you by :star: uptrace/uptrace.
Uptrace is an open source APM and blazingly fast
distributed tracing tool powered
by OpenTelemetry and ClickHouse. Give it a star as well!

Resources

Features

Installation

msgpack supports 2 last Go versions and requires support for
Go modules. So make sure to initialize a Go module:

shell
go mod init github.com/my/repo

And then install msgpack/v5 (note v5 in the import; omitting it is a popular mistake):

shell
go get github.com/vmihailenco/msgpack/v5

Quickstart

go
import "github.com/vmihailenco/msgpack/v5" func ExampleMarshal() { type Item struct { Foo string } b, err := msgpack.Marshal(&Item{Foo: "bar"}) if err != nil { panic(err) } var item Item err = msgpack.Unmarshal(b, &item) if err != nil { panic(err) } fmt.Println(item.Foo) // Output: bar }

See also

Contributors

Thanks to all the people who already contributed!

<a href="https://github.com/vmihailenco/msgpack/graphs/contributors"> <img src="https://contributors-img.web.app/image?repo=vmihailenco/msgpack" /> </a>

Contributors

Showing top 12 contributors by commit count.

View all contributors on GitHub →

This article is auto-generated from vmihailenco/msgpack via the GitHub API.Last fetched: 6/18/2026