Which icon libraries shadcn/ui supports, how to set one in components.json, and how to switch, trim, or extend the icon libraries in the shadcn/ui kit for Figma.
The kit supports the five icon libraries available in shadcn/create:
shadcn/ui reads the iconLibrary value in components.json and uses it when the CLI adds components. These are the accepted values and the package each one installs. Counts are rounded and describe the free sets.
| Library | iconLibrary value | Package | Icons | License | In the Figma kit |
|---|---|---|---|---|---|
| Lucide | lucide | lucide-react | 1,600+ | ISC | Yes, default |
| Hugeicons | hugeicons | @hugeicons/react and @hugeicons/core-free-icons | 4,000+ free | MIT (free set) | Yes |
| Phosphor | phosphor | @phosphor-icons/react | 1,500+ in six weights | MIT | Yes |
| Tabler Icons | tabler | @tabler/icons-react | 5,900+ | MIT | Yes |
| Remix Icon | remixicon | @remixicon/react | 3,000+ | Apache 2.0 | Yes |
| Radix Icons | radix | @radix-ui/react-icons | 300+ | MIT | No, add it as a custom library |
Which one to pick:
To set the library for a new project, pass it to shadcn create or answer the prompt during npx shadcn init. For an existing project, change iconLibrary in components.json, install the package, and re-add the components that render icons so the CLI regenerates their imports. Components accept any icon as a child, so a mixed period during migration works, but keep one library per product for a consistent stroke and grid.
The kit uses the same five libraries as shadcn create, and the Figma to shadcn/ui plugin writes imports for the library that is active in your file, so the icon you place in Figma is the icon the generated code imports.
Icon-library visibility is driven by boolean variables in the Style collection (icon-library/lucide, icon-library/huge, icon-library/phosphor, icon-library/tabler, icon-library/remix). Set exactly one to true.
The default is Lucide. To use a different one:
icon-library/* boolean for the library you want to true, and set the currently active one to false. Keep exactly one enabled.
You can also switch the icon library from the Figma to shadcn/ui plugin. Its Create tab applies your icon-library choice across all 8 styles.
The kit includes all five libraries, which adds weight. Choose a single library and remove the rest to reduce your file size. A smaller file loads faster and makes component search more responsive.
IconPlaceholder component, delete the instances for any libraries you no longer need.icon-library/* booleans for the libraries you removed.You can swap the icon inside the IconPlaceholder component. For example, to change the Smile icon to another icon:
IconPlaceholder instance.
If an icon is missing from one of the libraries, add it:
The kit is designed to let you plug in your own icon library and use it across components with minimal effort.
A good icon library should:
Sticking to a single, high-quality library from the start keeps your project visually consistent, avoids time-consuming icon replacement later, and keeps the design looking professional.
IconPlaceholder component.IconPlaceholder.icon-library/custom).icon-library/* booleans. Note that the Style collection has 8 modes (one per style), so set the values across all of them so your library stays active in every style.IconPlaceholder.That's all. You can now use your custom icons across every component in the kit.
In some cases Figma may render the IconPlaceholder component larger than intended. This is a known issue that can be resolved by regenerating instances:
Command + /Regenerate all instances (slow).Lucide. New projects created with shadcn create or npx shadcn init install lucide-react unless you choose another library, and the Figma kit ships with Lucide enabled.
Six values are accepted in components.json: lucide, hugeicons, phosphor, tabler, remixicon, and radix. The Figma kit includes the first five.
Yes. Any React icon component works inside shadcn/ui components. The iconLibrary setting only controls which package the CLI imports when it adds components. In Figma, add the library with the custom icons method above.
Lucide (ISC), Phosphor, Tabler, Radix (MIT), and Remix Icon (Apache 2.0) are free for commercial use. Hugeicons is MIT for the free set and paid for the Pro styles. Check each project's license page before shipping.
Components such as Button size their child SVGs through [&_svg] selectors, so a plain <Settings /> renders at the right size. Outside of components, use the size utilities, for example className="size-4" for 16px.
Yes. The Figma to shadcn/ui plugin reads which icon-library/* boolean is active and writes imports for that package, using each library's naming convention (for example IconSettings for Tabler and RiSettings3Line for Remix Icon).