Tailwind CSS interview question · Most asked
How does Tailwind compare with Bootstrap or writing your own CSS?
Summary
Bootstrap gives pre-built components (buttons, navbars) with a fixed look you override; Tailwind gives low-level utilities so you build any design. Hand-written CSS gives full control but needs naming, organisation and tends to grow and become unsafe to change. Tailwind trades class names in HTML for consistency and maintainability.
Longer Answer
Teams often pair Tailwind with headless component libraries (Radix, Headless UI) or copy-paste kits (shadcn/ui) to get components without a fixed look.
Key Points
- Bootstrap: components, fixed style.
- Tailwind: utilities, any design.
- Custom CSS: control, harder to maintain.
- Headless libraries add behaviour.
Explanation
What interviewers look for
A balanced comparison with real use cases.
More most-asked Tailwind CSS questions
- How do you customize Tailwind's design tokens in v4?
- Explain Tailwind's responsive design approach.
- How does Tailwind decide which CSS to generate?
- Why doesn't className={`bg-${color}-500`} work, and what should you do instead?
- What is Tailwind CSS and what does 'utility-first' mean?
- What changed in Tailwind CSS v4 compared with v3?
- How do you make Tailwind interfaces accessible?
- What's the difference between flex and grid in Tailwind, and when do you use each?