# happykit/flags

⛳️ Feature Flags for Next.js

Repository: https://github.com/happykit/flags
Canonical: https://ross.abutalabs.com/products/flags
Homepage: https://happykit.dev
Language: TypeScript
License: MIT
License Family: permissive
Topics: nextjs, react, reactjs, feature-flags, feature-toggles
Archived: true
Last push: 2025-12-12T05:59:58+00:00

## Health v2 (maintenance only)
Score: 10/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 56, release rhythm 8, longevity 100
- inputs: {"age_days": 2187, "days_push": 264, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: archived
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1037, forks 12 (observed 2026-08-28T04:03:19.527365+00:00)

## What it is
A lightweight (2 kB) TypeScript SDK that adds feature flags to Next.js applications via a useFlags() React hook or getFlags() function, integrating with the HappyKit Flags hosted service. It supports App Router, SSR, SSG, middleware, edge functions, user targeting, custom rules, and rollouts.

## Use cases
- add feature flags to a next.js app
- toggle features with a react hook
- server-side rendered feature flags
- feature flags for static site generation
- user targeting and percentage rollouts in nextjs
- edge middleware feature flags

## When to choose
- you already have a legacy HappyKit account and data export needs
- studying how framework-level flag SDKs integrate with Next.js rendering modes

## When to avoid
- starting a new project - the HappyKit hosted service shut down on May 30th
- you need a maintained, actively supported feature flag solution
- you want a self-hosted or provider-agnostic flag system

## Facets
- artifact type: library
- maturity: abandoned
- function: feature-flags, sdk, middleware
- domain: web-development, frontend, developer-tools
- platform: cross-platform
- tags: nextjs, react, feature-toggles, ssr, edge-functions, discontinued-service, nodejs, web-server

## Member repositories
- happykit/flags (main) score 10

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:03:19.527365+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-30T07:04:23.434633+00:00, confidence not recorded.
  - readme: https://github.com/happykit/flags (fetched 2026-08-28T04:03:19.527365+00:00, sha 5dc825789cf3)
  - homepage: https://happykit.dev (fetched 2026-08-29T13:05:13.576347+00:00, sha 0a86fe107889)
- Data as of 2026-08-30T08:39:29.467469+00:00.
