Tailwind CSS Border Radius
Apply rounded corners in Tailwind CSS with rounded-sm to rounded-full. Learn per-side rounding, responsive border radius, and custom arbitrary values.
Interactive Border Radius Playground
Try each class live and inspect the CSS output.
rounded-lgborder-radius: 0.5rem;Rounded corners are a small detail that makes a UI feel considered. In Tailwind CSS, the rounded-* utilities control border radius without custom CSS. Use them to soften layouts, make components stand out, and keep your design language consistent.
This guide gives you complete control over rounded-* classes—from basics to responsive tricks, custom values, and layout patterns used in modern interfaces.
How to apply Border Radius in Tailwind CSS
Format: rounded-{size}. Tailwind ships with sm, md, lg, xl, 2xl, and full (for perfect circles).
1<div class="rounded ..."></div>2<div class="rounded-md ..."></div>3<div class="rounded-lg ..."></div>4<div class="rounded-full ..."></div>
Rounded
Rounded-md
Rounded-lg
Rounded-full
Targeting Specific Corners
You don’t always want every corner rounded. Tailwind lets you target sides and single corners.
Tailwind No Rounded Button
1<button class=" border-none rounded-none....">Button</button>
Tailwind Border Pill Button
1<button type="button" class="rounded-full....">Click me</button>
Top and Bottom Only
rounded-t-* rounds the top corners. rounded-b-* rounds the bottom corners.
1<div2 class="flex space-x-4 justify-center items-center p-5 text-white font-bold bg-indigo-100 rounded-t-md"3>4 <div class="rounded-t-md bg-indigo-500 p-4">Top borders Only</div>5</div>
1<div2 class="flex space-x-4 justify-center items-center p-5 text-white font-bold bg-indigo-100 rounded-t-md"3>4 <div class="rounded-b-lg bg-indigo-500 p-4">bottom borders Only</div>5</div>
One-Sided / Single Corner Radius
For precise control: rounded-tl-*, rounded-tr-*, and the logical versions rounded-ss-*, rounded-se-*, rounded-es-*, rounded-ee-*.
1<div2 class="flex space-x-4 justify-center items-center p-5 text-white font-bold bg-indigo-100 rounded-t-md"3>4 <div class="rounded-es-md bg-indigo-500 p-4">bottm End Start Border Only</div>5 <div class="rounded-tr-md bg-indigo-500 p-4">Top right end border</div>6</div>
Responsive Border Radius
Scale corners by breakpoint like any other utility.
1<div class="bg-indigo-50 flex-1 justify-center items-center p-4 rounded-t">2 <div3 class=" bg-indigo-500 max-w-md text-center text-white p-3 rounded-sm md:rounded-md lg:rounded-2xl"4 >5 Responsive border radius6 </div>7</div>
Responsive border radius
Using Arbitrary Values
When you need exact values, use bracket notation.
1<div class="bg-indigo-50 p-4 space-y-5 rounded-t ">2 <div class="bg-indigo-500 p-3 text-white text-center font-bold rounded-md">3 6px border radius4 </div>5 <div6 class=" bg-indigo-500 p-3 text-white text-center font-bold rounded-tr-3xl"7 >8 Top-right 1.5rem9 </div>10</div>
6px border radius
Top-right 1.5rem
You can use any CSS-compatible unit like em, rem, px, %.
Custom Border Radius in Tailwind Config
To maintain consistency across your project, define custom sizes in tailwind.config.js:
1module.exports = {2 theme: {3 extend: {4 borderRadius: {5 card: "0.75rem",6 cta: "1.25rem",7 },8 },9 },10};
1<div class="bg-indigo-50 p-4 flex justify-center items-center rounded-t ">2 <div class="flex-col bg-white p-4 rounded-card max-w-md">3 <h1 class="font-bold text-2xl mb-2">Card</h1>4 <p class="text-gray-500">This cards a Custom card radius</p>5 </div>6</div>
Card
This cards a Custom card radius
Interaction States: Hover and Focus
Radius can change on interaction like color or shadow.
1<div class="bg-indigo-50 p-4 flex justify-center items-center rounded-t ">2 <button3 class="bg-indigo-500 p-3 text-white font-bold rounded-md hover:rounded-lg focus:rounded-full transition-all"4 >5 Hover me6 </button>7</div>
transition-all keeps the change smooth instead of jumpy.
Real-World UI Component Examples
Card Layout
1<div class="bg-indigo-50 p-4 flex justify-center items-center rounded-t ">2 <div class="rounded-lg shadow-md p-3 bg-white max-w-md pb-5">3 <img4 class="object-cover rounded"5 src="https://images.unsplash.com/photo-1602143407151-7111542de6e8?w=500&auto=format&fit=crop&q=60&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxzZWFyY2h8N3x8cHJvZHVjdHxlbnwwfHwwfHx8MA%3D%3D"6 />7 <div class="flex-col">8 <h1 class="font-bold my-3 text-2xl">Product Card</h1>9 <p class="text-gray-600 my-2">10 This describes the different aspect of the product listed to allow you11 make better decison on whether to buy it or not.12 </p>13 <span class="flex my-2 text-gray-800 font-medium">$23</span>14 <button15 class="bg-indigo-500 w-full text-center font-bold text-white rounded-2xl py-2"16 >17 Buy18 </button>19 </div>20 </div>21</div>
Product Card
This describes the different aspect of the product listed to allow you make better decison on whether to buy it or not.
$23Rounded corners make the card visually distinct and tactile.
Avatar Image
1<div class="bg-indigo-50 p-4 flex justify-center items-center rounded-t ">2 <div class="rounded-lg shadow-md p-3 bg-white max-w-md pb-5">3 <img4 src="https://images.unsplash.com/photo-1534528741775-53994a69daeb?w=200&auto=format&fit=crop&q=60&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxzZWFyY2h8MTB8fHByb2ZpbGV8ZW58MHx8MHx8fDA%3D"5 class="w-24 h-24 rounded-full"6 />7 </div>8</div>
Perfect for circular profile photos or initials.
Modal Header
1<div class="bg-indigo-50 p-4 flex justify-center items-center rounded-t ">2 <div class="rounded-lg shadow-md p-3 bg-white max-w-md pb-5">3 <div class="rounded-t-lg bg-indigo-400 p-4 text-white font-bold">4 Modal Title5 </div>6 </div>7</div>
Modal Title
Top corners only for modals that sit on rectangular content areas.
Best Practices
-
Prefer semantic
rounded-*sizes before jumping to arbitrary values. -
Define tokens in your config to keep a consistent system.
-
Use
rounded-noneto reset unwanted rounding in nested UIs. -
Pair with
shadow-*orring-*for depth. -
Animate radius changes on hover/focus with
transition-*.
Tailwind Border Radius classes and Properties
| Class | Properties |
|---|---|
| rounded-none | border-radius: 0px; |
| rounded-sm | border-radius: 0.125rem; 2px |
| rounded | border-radius: 0.25rem; 4px |
| rounded-md | border-radius: 0.375rem; 6px |
| rounded-lg | border-radius: 0.5rem; 8px |
| rounded-xl | border-radius: 0.75rem; 12px |
| rounded-2xl | border-radius: 1rem; 16px |
| rounded-3xl | border-radius: 1.5rem; 24px |
| rounded-full | border-radius: 9999px; |
| rounded-s-none | border-start-start-radius: 0px; border-end-start-radius: 0px; |
| rounded-s-sm | border-start-start-radius: 0.125rem; border-end-start-radius: 0.125rem; |
| rounded-s | border-start-start-radius: 0.25rem; border-end-start-radius: 0.25rem; |
| rounded-s-md | border-start-start-radius: 0.375rem; border-end-start-radius: 0.375rem; |
| rounded-s-lg | border-start-start-radius: 0.5rem; border-end-start-radius: 0.5rem; |
| rounded-s-xl | border-start-start-radius: 0.75rem; border-end-start-radius: 0.75rem; |
| rounded-s-2xl | border-start-start-radius: 1rem; border-end-start-radius: 1rem; |
| rounded-s-3xl | border-start-start-radius: 1.5rem; border-end-start-radius: 1.5rem; |
| rounded-s-full | border-start-start-radius: 9999px; border-end-start-radius: 9999px; |
| rounded-e-none | border-start-end-radius: 0px; border-end-end-radius: 0px; |
| rounded-e-sm | border-start-end-radius: 0.125rem; border-end-end-radius: 0.125rem; |
| rounded-e | border-start-end-radius: 0.25rem; border-end-end-radius: 0.25rem; |
| rounded-e-md | border-start-end-radius: 0.375rem; border-end-end-radius: 0.375rem; |
| rounded-e-lg | border-start-end-radius: 0.5rem; border-end-end-radius: 0.5rem; |
| rounded-e-xl | border-start-end-radius: 0.75rem; border-end-end-radius: 0.75rem; |
| rounded-e-2xl | border-start-end-radius: 1rem; border-end-end-radius: 1rem; |
| rounded-e-3xl | border-start-end-radius: 1.5rem; border-end-end-radius: 1.5rem; |
| rounded-e-full | border-start-end-radius: 9999px; border-end-end-radius: 9999px; |
| rounded-t-none | border-top-left-radius: 0px; border-top-right-radius: 0px; |
| rounded-t-sm | border-top-left-radius: 0.125rem; border-top-right-radius: 0.125rem; |
| rounded-t | border-top-left-radius: 0.25rem; border-top-right-radius: 0.25rem; |
| rounded-t-md | border-top-left-radius: 0.375rem; border-top-right-radius: 0.375rem; |
| rounded-t-lg | border-top-left-radius: 0.5rem; border-top-right-radius: 0.5rem; |
| rounded-t-xl | border-top-left-radius: 0.75rem; border-top-right-radius: 0.75rem; |
| rounded-t-2xl | border-top-left-radius: 1rem; border-top-right-radius: 1rem; |
| rounded-t-3xl | border-top-left-radius: 1.5rem; border-top-right-radius: 1.5rem; |
| rounded-t-full | border-top-left-radius: 9999px; border-top-right-radius: 9999px; |
| rounded-r-none | border-top-right-radius: 0px; border-bottom-right-radius: 0px; |
| rounded-r-sm | border-top-right-radius: 0.125rem; border-bottom-right-radius: 0.125rem; |
| rounded-r | border-top-right-radius: 0.25rem; border-bottom-right-radius: 0.25rem; |
| rounded-r-md | border-top-right-radius: 0.375rem; border-bottom-right-radius: 0.375rem; |
| rounded-r-lg | border-top-right-radius: 0.5rem; border-bottom-right-radius: 0.5rem; |
| rounded-r-xl | border-top-right-radius: 0.75rem; border-bottom-right-radius: 0.75rem; |
| rounded-r-2xl | border-top-right-radius: 1rem; border-bottom-right-radius: 1rem; |
| rounded-r-3xl | border-top-right-radius: 1.5rem; border-bottom-right-radius: 1.5rem; |
| rounded-r-full | border-top-right-radius: 9999px; border-bottom-right-radius: 9999px; |
| rounded-b-none | border-bottom-right-radius: 0px; border-bottom-left-radius: 0px; |
| rounded-b-sm | border-bottom-right-radius: 0.125rem; border-bottom-left-radius: 0.125rem; |
| rounded-b | border-bottom-right-radius: 0.25rem; border-bottom-left-radius: 0.25rem; |
| rounded-b-md | border-bottom-right-radius: 0.375rem; border-bottom-left-radius: 0.375rem; |
| rounded-b-lg | border-bottom-right-radius: 0.5rem; border-bottom-left-radius: 0.5rem; |
| rounded-b-xl | border-bottom-right-radius: 0.75rem; border-bottom-left-radius: 0.75rem; |
| rounded-b-2xl | border-bottom-right-radius: 1rem; border-bottom-left-radius: 1rem; |
| rounded-b-3xl | border-bottom-right-radius: 1.5rem; border-bottom-left-radius: 1.5rem; |
| rounded-b-full | border-bottom-right-radius: 9999px; border-bottom-left-radius: 9999px; |
| rounded-l-none | border-top-left-radius: 0px; border-bottom-left-radius: 0px; |
| rounded-l-sm | border-top-left-radius: 0.125rem; border-bottom-left-radius: 0.125rem; |
| rounded-l | border-top-left-radius: 0.25rem; border-bottom-left-radius: 0.25rem; |
| rounded-l-md | border-top-left-radius: 0.375rem; border-bottom-left-radius: 0.375rem; |
| rounded-l-lg | border-top-left-radius: 0.5rem; border-bottom-left-radius: 0.5rem; |
| rounded-l-xl | border-top-left-radius: 0.75rem; border-bottom-left-radius: 0.75rem; |
| rounded-l-2xl | border-top-left-radius: 1rem; border-bottom-left-radius: 1rem; |
| rounded-l-3xl | border-top-left-radius: 1.5rem; border-bottom-left-radius: 1.5rem; |
| rounded-l-full | border-top-left-radius: 9999px; border-bottom-left-radius: 9999px; |
| rounded-ss-none | border-start-start-radius: 0px; |
| rounded-ss-sm | border-start-start-radius: 0.125rem; 2px |
| rounded-ss | border-start-start-radius: 0.25rem; 4px |
| rounded-ss-md | border-start-start-radius: 0.375rem; 6px |
| rounded-ss-lg | border-start-start-radius: 0.5rem; 8px |
| rounded-ss-xl | border-start-start-radius: 0.75rem; 12px |
| rounded-ss-2xl | border-start-start-radius: 1rem; 16px |
| rounded-ss-3xl | border-start-start-radius: 1.5rem; 24px |
| rounded-ss-full | border-start-start-radius: 9999px; |
| rounded-se-none | border-start-end-radius: 0px; |
| rounded-se-sm | border-start-end-radius: 0.125rem; 2px |
| rounded-se | border-start-end-radius: 0.25rem; 4px |
| rounded-se-md | border-start-end-radius: 0.375rem; 6px |
| rounded-se-lg | border-start-end-radius: 0.5rem; 8px |
| rounded-se-xl | border-start-end-radius: 0.75rem; 12px |
| rounded-se-2xl | border-start-end-radius: 1rem; 16px |
| rounded-se-3xl | border-start-end-radius: 1.5rem; 24px |
| rounded-se-full | border-start-end-radius: 9999px; |
| rounded-ee-none | border-end-end-radius: 0px; |
| rounded-ee-sm | border-end-end-radius: 0.125rem; 2px |
| rounded-ee | border-end-end-radius: 0.25rem; 4px |
| rounded-ee-md | border-end-end-radius: 0.375rem; 6px |
| rounded-ee-lg | border-end-end-radius: 0.5rem; 8px |
| rounded-ee-xl | border-end-end-radius: 0.75rem; 12px |
| rounded-ee-2xl | border-end-end-radius: 1rem; 16px |
| rounded-ee-3xl | border-end-end-radius: 1.5rem; 24px |
| rounded-ee-full | border-end-end-radius: 9999px; |
| rounded-es-none | border-end-start-radius: 0px; |
| rounded-es-sm | border-end-start-radius: 0.125rem; 2px |
| rounded-es | border-end-start-radius: 0.25rem; 4px |
| rounded-es-md | border-end-start-radius: 0.375rem; 6px |
| rounded-es-lg | border-end-start-radius: 0.5rem; 8px |
| rounded-es-xl | border-end-start-radius: 0.75rem; 12px |
| rounded-es-2xl | border-end-start-radius: 1rem; 16px |
| rounded-es-3xl | border-end-start-radius: 1.5rem; 24px |
| rounded-es-full | border-end-start-radius: 9999px; |
| rounded-tl-none | border-top-left-radius: 0px; |
| rounded-tl-sm | border-top-left-radius: 0.125rem; 2px |
| rounded-tl | border-top-left-radius: 0.25rem; 4px |
| rounded-tl-md | border-top-left-radius: 0.375rem; 6px |
| rounded-tl-lg | border-top-left-radius: 0.5rem; 8px |
| rounded-tl-xl | border-top-left-radius: 0.75rem; 12px |
| rounded-tl-2xl | border-top-left-radius: 1rem; 16px |
| rounded-tl-3xl | border-top-left-radius: 1.5rem; 24px |
| rounded-tl-full | border-top-left-radius: 9999px; |
| rounded-tr-none | border-top-right-radius: 0px; |
| rounded-tr-sm | border-top-right-radius: 0.125rem; 2px |
| rounded-tr | border-top-right-radius: 0.25rem; 4px |
| rounded-tr-md | border-top-right-radius: 0.375rem; 6px |
| rounded-tr-lg | border-top-right-radius: 0.5rem; 8px |
| rounded-tr-xl | border-top-right-radius: 0.75rem; 12px |
| rounded-tr-2xl | border-top-right-radius: 1rem; 16px |
| rounded-tr-3xl | border-top-right-radius: 1.5rem; 24px |
| rounded-tr-full | border-top-right-radius: 9999px; |
| rounded-br-none | border-bottom-right-radius: 0px; |
| rounded-br-sm | border-bottom-right-radius: 0.125rem; 2px |
| rounded-br | border-bottom-right-radius: 0.25rem; 4px |
| rounded-br-md | border-bottom-right-radius: 0.375rem; 6px |
| rounded-br-lg | border-bottom-right-radius: 0.5rem; 8px |
| rounded-br-xl | border-bottom-right-radius: 0.75rem; 12px |
| rounded-br-2xl | border-bottom-right-radius: 1rem; 16px |
| rounded-br-3xl | border-bottom-right-radius: 1.5rem; 24px |
| rounded-br-full | border-bottom-right-radius: 9999px; |
| rounded-bl-none | border-bottom-left-radius: 0px; |
| rounded-bl-sm | border-bottom-left-radius: 0.125rem; 2px |
| rounded-bl | border-bottom-left-radius: 0.25rem; 4px |
| rounded-bl-md | border-bottom-left-radius: 0.375rem; 6px |
| rounded-bl-lg | border-bottom-left-radius: 0.5rem; 8px |
| rounded-bl-xl | border-bottom-left-radius: 0.75rem; 12px |
| rounded-bl-2xl | border-bottom-left-radius: 1rem; 16px |
| rounded-bl-3xl | border-bottom-left-radius: 1.5rem; 24px |
| rounded-bl-full | border-bottom-left-radius: 9999px; |
✨ What's Next?
Now that you’ve mastered Tailwind Border radius, try experimenting with:
Windframe Tailwind blocks
Windframe is an AI visual editor for rapidly building stunning web UIs & websites
Start building stunning web UIs & websites!

