rounded-r: Tailwind CSS Border Radius class

The rounded-r class in Tailwind CSS applies the default border-radius to the right side of an element — specifically the top-right and bottom-right corners.


rounded-r

The rounded-r class in Tailwind CSS applies the default border-radius to the right side of an element — specifically the top-right and bottom-right corners. It’s useful when you want smooth rounding on one side only, such as in button groups, input fields, or card edges.

Syntax

html
<div class="rounded-r">...</div>

Example Code

html
<div class="flex">
<input type="text" class="border px-4 py-2 rounded-l" placeholder="Email" />
<button class="bg-blue-600 text-white px-4 py-2 rounded-r">
Subscribe
</button>
</div>

Preview

In this case, rounded-r gives the button a rounded right edge, while rounded-l shapes the input's left side — perfect for building grouped elements.

How to Use

Add the rounded-r class directly to your HTML element:

html
<div class="rounded-r">
<!-- Your content here -->
</div>

Responsive Usage

Use Tailwind's responsive prefixes to apply rounded-r at specific breakpoints:

html
<div class="sm:rounded-r md:rounded-r lg:rounded-r">
Responsive element
</div>
  • sm:rounded-r — applies from 640px and up
  • md:rounded-r — applies from 768px and up
  • lg:rounded-r — applies from 1024px and up

Customization

You can extend or override this utility in your tailwind.config.js. See the Tailwind CSS documentation for details on customizing your theme.

Windframe is an AI visual editor for rapidly building stunning web UIs & websites

Start building stunning web UIs & websites!

Build from scratch or select prebuilt tailwind templates