# gleam_crypto

> Cryptography for Gleam on Erlang and JavaScript

Source: https://talira.ai/catalog/gleam-crypto-b6zytyn4
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library
- Categories: [libraries / cryptography](https://talira.ai/categories/libraries/cryptography), [languages / gleam](https://talira.ai/categories/languages/gleam)
- Licence: Apache-2.0[^2]
- Pricing: Free and open source[^2]
- Free tier: yes[^2]
- Backed by: [The Gleam Project](https://talira.ai/orgs/gleam-project.md)

gleam_crypto is the [Gleam](https://talira.ai/catalog/gleam-ywzz9yr6.md) project's cryptography library for both the Erlang and JavaScript targets: hashing (MD5, SHA-1 and the SHA-2 family), HMAC, cryptographically strong random bytes, constant-time comparison, and signing and verifying messages. On JavaScript it uses Node's crypto APIs, available in Node.js, Bun and Deno but not in browsers.

## Links

- GitHub: https://github.com/gleam-lang/crypto
- Docs: https://gleam-crypto.hexdocs.pm/

## Problems it solves

- hash data with SHA-256 in Gleam
- generate secure random bytes in Gleam
- sign and verify messages in a Gleam app

## Features

- MD5, SHA-1 and SHA-2 hashing
- HMAC
- strong random bytes
- constant-time secure compare
- message signing and verification
- Erlang and JavaScript targets

## Limitations

- On JavaScript it needs Node's crypto APIs, so it doesn't work in web browsers.[^1]

## Trust

Overall: 0.25 out of 1.
Signals: maintenance 0.27, adoption 0.36, momentum 0.07, community 0.34, backing 0.30, extensibility 0.00.

- latest release v1.6.0 7 months ago
- 60 GitHub stars
- 6 contributors
- accepts sponsorship (Github, Github, Github)
- backed by The Gleam Project

Warnings:

- last commit 4 months ago

## Related

- Works with [Gleam](https://talira.ai/catalog/gleam-ywzz9yr6.md)

## Sources

[^1]: https://gleam-crypto.hexdocs.pm/ (checked 29 Nov 2026)
[^2]: https://github.com/gleam-lang/crypto/blob/main/LICENSE (checked 29 Nov 2026)
