# cuth/postcss-pxtorem

Convert pixel units to rem (root em) units using PostCSS

Repository: https://github.com/cuth/postcss-pxtorem
Canonical: https://ross.abutalabs.com/products/postcss-pxtorem
Language: JavaScript
License: MIT
License Family: permissive
Topics: postcss, rem-units, pixel-units
Last push: 2024-04-16T01:20:52+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": 4516, "days_push": 870, "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 2159, forks 173 (observed 2026-08-28T04:06:20.741003+00:00)

## What it is
A PostCSS plugin that converts pixel (px) units in CSS to rem (root em) units. It is configurable via options such as root value, property lists, selector blacklists, and media query handling.

## Use cases
- convert px to rem in my css build
- make my site respect browser font size settings
- postcss plugin to generate rem units from pixels
- convert font-size px values to rem automatically
- responsive typography with rem units
- exclude node_modules css from px to rem conversion

## When to choose
- you use PostCSS and want scalable, accessible rem-based sizing
- you want fine-grained control over which properties and selectors are converted
- you need configurable root value and precision for unit conversion

## When to avoid
- you don't use a PostCSS-based build pipeline
- you need runtime unit conversion in the browser
- you want px to viewport units (vw/vh) conversion instead

## Facets
- artifact type: plugin
- maturity: stable
- function: css-framework, developer-tools
- domain: web-development, frontend
- platform: cross-platform
- tags: postcss-plugin, css-units, px-to-rem, responsive-design, accessibility, nodejs

## Member repositories
- cuth/postcss-pxtorem (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:20.741003+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-30T02:50:19.562929+00:00, confidence not recorded.
  - readme: https://github.com/cuth/postcss-pxtorem (fetched 2026-08-28T04:06:20.741003+00:00, sha c18c9ddb87e7)
  - registry_npm: https://registry.npmjs.org/postcss-pxtorem (fetched 2026-08-29T10:30:28.860502+00:00, sha 1be33a158006)
- Data as of 2026-08-30T08:39:29.467469+00:00.
