Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

ai-elements

Skill by vercel

Builds AI chat interfaces with AI Elements, a component library built on shadcn/ui. It provides pre-built conversation, message, tool display and prompt input components for developers building chatbots or AI assistant UIs.

  • Score 83
  • 2.5k stars
  • NOASSERTION
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install ai-elements

Built from the published package, never by AI.

git clone --depth 1 https://github.com/vercel/ai-elements /tmp/ai-elements && mkdir -p ~/.claude/skills && cp -r /tmp/ai-elements/skills/ai-elements ~/.claude/skills/ai-elements

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install ai-elements in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

AI Elements is a component library and custom registry built on top of shadcn/ui. It provides pre-built components such as conversations and messages to help developers build AI-native applications. You can install components with the AI Elements CLI or the shadcn/ui CLI, and the component code is added to your project, by default under @/components/ai-elements/.

Because the code lives in your project, you can open and change the component files directly. Components accept standard HTML attributes, so you can add your own styles or behavior. The skill is aimed at developers who want to build a chatbot, an AI assistant UI, or any AI-powered chat interface in a Next.js project that uses the AI SDK.

Written from the project's SKILL.md and checked against it.

What it can do

  • Conversation and message componentsProvides pre-built chat components such as Message, MessageContent and MessageResponse.
  • Tool displays and prompt inputsIncludes pre-built components for tool displays and prompt inputs, per the skill description.
  • Component installationAdds component code and dependencies to the project using the AI Elements or shadcn/ui CLI.
  • Component customizationLets you edit the installed component file, for example to remove the rounding on Message.
  • Extensible propsComponents extend native HTML attributes, so standard div props can be passed through.
  • Troubleshooting guidanceCovers styling, import path, theme switching and CLI issues with fixes.
  • Component reference docsPoints to a references/ folder with detailed documentation for each component.

What you need

  • Node.js 18 or later
  • A Next.js project with the AI SDK installed
  • shadcn/ui installed, or installed automatically by the CLI
  • Tailwind CSS 4 with shadcn/ui base styles
  • AI_GATEWAY_API_KEY in env.local (highly recommended)

Try asking

  • Add AI Elements message components to my Next.js chat page.
  • Install the AI Elements conversation components in my project.
  • Remove the rounded corners from the AI Elements Message component.

Good to know

  • The source says the default theme switching expects a data-theme attribute on the html element.
  • Styling depends on a Tailwind 4 setup with shadcn/ui base styles.
  • The source describes a Next.js project as a prerequisite.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: skills/ai-elements/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Inside the skill

  • SKILL.md7 KB
  • references/agent.md4 KB
  • references/artifact.md3 KB
  • references/attachments.md6 KB
  • references/audio-player.md5 KB
Show all 129 files
  • references/canvas.md1 KB
  • references/chain-of-thought.md3 KB
  • references/checkpoint.md5 KB
  • references/code-block.md5 KB
  • references/commit.md6 KB
  • references/confirmation.md9 KB
  • references/connection.md1 KB
  • references/context.md6 KB
  • references/controls.md971 B
  • references/conversation.md7 KB
  • references/edge.md2 KB
  • references/environment-variables.md4 KB
  • references/file-tree.md2 KB
  • references/image.md4 KB
  • references/inline-citation.md11 KB
  • references/jsx-preview.md3 KB
  • references/message.md9 KB
  • references/mic-selector.md8 KB
  • references/model-selector.md4 KB
  • references/node.md3 KB
  • references/open-in-chat.md3 KB
  • references/package-info.md3 KB
  • references/panel.md1 KB
  • references/persona.md5 KB
  • references/plan.md3 KB

And 99 more files on GitHub.

Alternatives to ai-elements

All alternatives →
openclaw-github-repo-commandersickn33
94

Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.

AAA Skill 50k
gradiogradio-app
94

Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.

AAA Skill 44k
hig-components-menussickn33
94

Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.

AAA Skill 50k
fastapi-templateswshobson
94

Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.

AAA Skill 43k
appfunctionsandroid
94

Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.

AAA Skill 11k
agent-qa-authoringsickn33
94

Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.

AAA Skill 50k

Compare with openclaw-github-repo-commander, gradio or hig-components-menus

ai-elements: common questions

Where are AI Elements components added in my project?

By default they are added to @/components/ai-elements/, or to whichever folder is set in your shadcn components settings.

Do I need an AI Gateway API key to use AI Elements?

The source highly recommends adding AI_GATEWAY_API_KEY to env.local so you do not need a separate API key from every provider. It also says AI Gateway gives $5 in usage per month.

Why are my AI Elements components not styled?

The source says your project must be configured for shadcn/ui in Tailwind 4, with a globals.css file that imports Tailwind and includes the shadcn/ui base styles.

How do I install ai-elements?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is ai-elements free?

The code is published under the NOASSERTION licence. The service it connects to may have its own pricing.

Is ai-elements safe to use?

It scores 83 of 100. Grades: maintenance B, licence F, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to ai-elements?

Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.

ai-elements Install

Add to stack

Loading.