# max()

*noun*

say it: **“MAKS”** **/mæks/**

A CSS function that uses the largest of the values you give it, often to set a size that can grow but never drop below a floor.

## What does `max()` do in CSS?

`max()` uses the largest of several values, so an element never gets smaller than one of them.

```css
.sidebar { width: max(200px, 20%); }
```

## In a sentence

- “I set the padding to **max()** of 1rem and 5%, so it grows on big screens but never gets thinner than 1rem.”

Level: Freelancer · [More CSS terms at this level](https://www.ask-codey.com/glossary?category=css&level=4)

Updated: November 9, 2026

Source: https://www.ask-codey.com/glossary/max-css
