Shadcn for Phoenix, and what 1.4 million downloads taught us

Every Phoenix developer has written the same button a hundred times. The same modal, the same table, the same form field with the same slightly-off spacing. We were doing it across every client project, and so was everyone else, all in their own silos.

Petal Components is our answer: one good version of each. Buttons, inputs, modals, tables, the whole kit, styled with Tailwind and written as plain HEEx. You add the dependency, and <.button> and <.modal> are just there.

The Select component in the Petal playground, light mode The same Select component in dark mode

One component, both themes. A plain native select on a shared field surface, no JavaScript required.

People call it "Shadcn for Phoenix" and that's fair. Like Shadcn, the components are meant to be used and owned, not treated as a black box. They look right out of the box and get out of your way the moment you want something different.

It's open source and free, and it has now been downloaded more than 1.4 million times. That number still catches me off guard. It runs in production at companies I never would have guessed, from Woolworths to NFI, a logistics operation moving real freight around the world.

A few things all those downloads taught us.

Boring is a feature. The components people reach for most are the plainest ones. Nobody wants a clever button. They want a button that looks right, works in light and dark, and never surprises them.

Dark mode is not optional. Every component ships light and dark from day one. Retrofitting it later is misery, and developers notice the second it's missing.

Conventions travel. Because every component follows the same shape, someone can guess the API of one they've never used and usually be right. That consistency is worth more than any single fancy component, and it turns out to be exactly what AI agents need to use the library correctly too. More on that another day.

We're still adding to it, and the roadmap is mostly whatever people ask for. If there's something you build over and over, tell us. Odds are everyone else is building it too.