# vercel/arg

Simple argument parsing

Repository: https://github.com/vercel/arg
Canonical: https://ross.abutalabs.com/products/arg
Homepage: https://npmjs.com/arg
Language: JavaScript
License: MIT
License Family: permissive
Topics: argument, parser, argv, cli, command
Last push: 2024-07-18T14:08:05+00:00

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

## Adoption (not part of the score)
Stars 1292, forks 57 (observed 2026-08-28T04:04:16.086371+00:00)

## What it is
arg is a small, unopinionated CLI argument parsing library for Node.js that maps command-line flags to typed values via a simple spec object. It performs no validation, leaving requirement checking to the application.

## Use cases
- parse command-line arguments in a node script
- handle flags and aliases in a cli tool
- parse --port=1234 style options with types
- support repeated flags like -vvv
- collect positional arguments from argv

## When to choose
- you want a tiny, dependency-free argument parser
- you need typed flag parsing without validation overhead
- you prefer handling required-option checks yourself

## When to avoid
- you need built-in validation, help text generation, or subcommands
- you want a batteries-included CLI framework
- you need parsing outside Node.js

## Facets
- artifact type: library
- maturity: maintenance
- function: parser, cli
- domain: developer-tools, parsers
- platform: cli
- tags: argv-parsing, argument-parser, minimal, unopinionated, command-line, nodejs, javascript

## Member repositories
- vercel/arg (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:16.086371+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-30T04:54:45.692131+00:00, confidence not recorded.
  - readme: https://github.com/vercel/arg (fetched 2026-08-28T04:04:16.086371+00:00, sha 2cfb9dfbd1fa)
  - registry_npm: https://registry.npmjs.org/arg (fetched 2026-08-29T12:11:30.772988+00:00, sha ba80e1bcc81e)
- Data as of 2026-08-30T08:39:29.467469+00:00.
