Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

MCP

get_guide

Read a shadcn guide as Markdown: forms, styling, dark mode, colors, or right-to-left. Pass sections when you only need part of it.

Group
Inspect
Inputs
topicsections?
Access
Read-only

When to use it

  • To build a form: the library's setup, validation and each field type.
  • For theming, dark mode or right-to-left.

Inputs

InputType
topic"forms" | "react-hook-form" | "tanstack-form" | "formisch" | "styling" | "colors" | "rtl"

forms (which library), a form library, styling (tokens, dark mode), colors, rtl.

Type
"forms" | "react-hook-form" | "tanstack-form" | "formisch" | "styling" | "colors" | "rtl"
sections?string[]

Only these ## sections, by heading. All when unset.

Example prompts

Name the server, so the agent doesn't answer from memory:

Prompts
use shadcnio to build the signup form with React Hook Form and Zod
use shadcnio: how does dark mode work with these components?

Call and response

Asked “How do I validate this form with React Hook Form?”, the agent sends this call. The response is real, trimmed: long lists show their first items and long strings are cut.

Call
get_guide({ sections: ["Validation"], topic: "react-hook-form" })
Response
---
title: React Hook Form
description: "Build forms in React using React Hook Form and Zod."
---

## Validation

### Client-side

React Hook Form validates your form data using the Zod schema. Define a schema and pass it to the `resolver` option of the `useForm` hook.

```tsx title="example-form.tsx"
import { zodResolver } from "@hookform/resolvers/zod"
import { useForm } from "react-hook-form"
import * as z from "zod"

const formSchema = z.object({
  title: z.string(),
  description: z.string().optional(),
})

export const ExampleForm = () => {
  const form = useForm({
    resolver: zodResolver(formSchema),
    defaultValues: {
      title: "",
      description: "",
    },
```
…

Call it by hand

Your MCP client sends this for you. To try the tool without one, post the call yourself; the server answers in server-sent events, the result on the data: line.

Terminal
Sign in to get your config
Sign in with a Pro account, and this holds your MCP URL, ready to paste.

What your agent reads

The server's description of get_guide, one of the Inspect tools. Your agent reads it to decide when to call the tool:

tools/listget_guide.description
A guide as Markdown: forms and their libraries (each field type with its get_demo), styling and dark mode, colors, RTL. sections for only some.

Next

FAQ

Where is the form code in the guide?

Each field type (input, select, date picker, file upload, arrays…) has a demo in React Hook Form, TanStack Form and Formisch. The guide names the get_demo call under each; search_demos finds them too.

Which guides can I ask for?

Forms and their three libraries, styling and dark mode, colors and right-to-left. Setting up a project is get_project_setup.