🎉 Material UI v4 is out now! Check out the announcement blog post →
Tabs

Tabs

Tabs make it easy to explore and switch between different views.

Tabs organize and allow navigation between groups of content that are related and at the same level of hierarchy.

Simple Tabs

A simple example with no frills.

Item One

Wrapped Labels

Long labels will automatically wrap on tabs. If the label is too long for the tab, it will overflow and the text will not be visible.

Item One

Disabled Tab

A Tab can be disabled by setting disabled property.

Fixed Tabs

Fixed tabs should be used with a limited number of tabs and when consistent placement will aid muscle memory.

Full width

The variant="fullWidth" property should be used for smaller views. This demo also uses react-swipeable-views to animate the Tab transition, and allowing tabs to be swiped on touch devices.

Item One

Centered

The centered property should be used for larger views.

Scrollable Tabs

Automatic Scroll Buttons

Left and right scroll buttons will automatically be presented on desktop and hidden on mobile. (based on viewport width)

Item One

Forced Scroll Buttons

Left and right scroll buttons will be presented regardless of the viewport width.

Item One

Prevent Scroll Buttons

Left and right scroll buttons will never be presented. All scrolling must be initiated through user agent scrolling mechanisms (e.g. left/right swipe, shift-mousewheel, etc.)

Item One

Customized Tabs

If you have read the overrides documentation page but aren't confident jumping in, here's an example of how you can change the main color of the Tabs.

⚠️ While the material design specification encourages theming, this example is off the beaten path.

Ant Design UI powered by Material-UI

Nav Tabs

By default tabs use a button element, but you can provide your own custom tag or component. Here's an example of implementing tabbed navigation:

Icon Tabs

Tab labels may be either all icons or all text.