---
title: "StyleX Blocks"
description: "Copy-paste blocks and components for React, styled with StyleX."
url: "https://stylexblocks.com/"
agent:
  instructions: "Use this search API to find relevant components and blocks across this site with keywords or natural-language queries, instead of crawling individual pages. Results are returned in Markdown."
  endpoint: "https://stylexblocks.com/.well-known/search?q={query}"
  method: "GET"
  documentation: "https://developers.cloudflare.com/ai-search/how-to/search-for-agents/"
---

# StyleX Blocks

> Copy-paste blocks and components for React, styled with StyleX. Open source, installed as source you own via a shadcn-compatible registry, for Ark UI or Base UI.

122 components and 61 blocks. Every item is plain React + StyleX source — no runtime UI library to depend on beyond the behavior engine and the `@stylexblocks/ui` design tokens.

## Getting started

```sh
npx stylexblocks init                 # configure the project (Ark UI engine)
npx stylexblocks init --style base-ui # …or use Base UI as the behavior engine
npx stylexblocks add button dialog    # install items as source into src/components/ui
```

`init` writes `components.json` (registers the `@stylexblocks` shadcn registry namespace), adds `#components/*` / `#lib/*` subpath imports to package.json, and installs `@stylexjs/stylex`, `@stylexblocks/ui`, and the engine package. Two manual steps remain: import the generated `src/stylexblocks.css` once near the app entry, and register `@stylexjs/unplugin` in your bundler with `externalPackages: ["@stylexblocks/ui"]`.

Because the registry follows the shadcn schema, `npx shadcn add @stylexblocks/<name>` works too.

## MCP server

A remote MCP server (Streamable HTTP, no auth) at https://stylexblocks.com/mcp searches the catalog, returns docs and registry items, and gives install commands. Add it to Claude Code with:

```sh
claude mcp add --transport http stylexblocks https://stylexblocks.com/mcp
```

Server card: https://stylexblocks.com/.well-known/mcp/server-card.json

## Browse

- [Components](https://stylexblocks.com/components.md): every primitive, grouped by category
- [Blocks](https://stylexblocks.com/blocks.md): ready-made sections and screens
- [Changelog](https://stylexblocks.com/changelog/): what shipped when
- [llms.txt](https://stylexblocks.com/llms.txt) · [llms-full.txt](https://stylexblocks.com/llms-full.txt) · [Search](https://stylexblocks.com/.well-known/search?q=date%20picker) · [Registry index](https://stylexblocks.com/r/registry.json)
- Source: https://github.com/stylexblocks/stylexblocks
