# matoous/go-nanoid

Golang random IDs generator.

Repository: https://github.com/matoous/go-nanoid
Canonical: https://ross.abutalabs.com/products/go-nanoid
Language: Go
License: MIT
License Family: permissive
Topics: unique-id, uuid, golang, nanoid
Last push: 2025-12-03T17:08:00+00:00

## Health v2 (maintenance only)
Score: 48/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 55, release rhythm 8, longevity 100
- inputs: {"age_days": 3277, "days_push": 273, "days_rel": 693, "gap_med": null, "n_releases_24m": 1}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1599, forks 65 (observed 2026-08-28T04:05:09.446465+00:00)

## What it is
A Go implementation of the nanoid algorithm for generating compact, URL-safe unique identifiers using a cryptographically strong random generator. It produces 22-character IDs with the same uniqueness as UUIDs and supports custom alphabets and lengths.

## Use cases
- generate short unique IDs in Go
- replace UUIDs with compact URL-safe identifiers
- generate random IDs with a custom alphabet
- create database record keys that are safe in URLs
- generate session or request identifiers
- produce compact IDs for distributed systems

## When to choose
- you need compact, URL-safe unique IDs in a Go project
- you want UUID-level uniqueness in fewer characters
- you need custom alphabets or ID lengths
- you want a small, dependency-free ID generator

## When to avoid
- you need IDs that integrate with database UUID support
- you want a maintained, feature-rich ID solution like typeid
- you need sequential or sortable IDs
- you require strict cryptographic guarantees beyond standard CSPRNG usage

## Facets
- artifact type: library
- maturity: maintenance
- function: security, serialization, developer-tools
- domain: developer-tools, web-development, backend
- platform: go, cross-platform
- tags: nanoid, unique-id, uuid-alternative, random-id-generation, url-safe-ids

## Member repositories
- matoous/go-nanoid (main) score 48

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:09.446465+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:53:13.945413+00:00, confidence not recorded.
  - readme: https://github.com/matoous/go-nanoid (fetched 2026-08-28T04:05:09.446465+00:00, sha 22f74ef90a79)
- Data as of 2026-08-30T08:39:29.467469+00:00.
