Web platform features explorer

if()

Limited availability
Groups: CSS

The if() CSS function is an inline conditional value that returns a value based on a set of conditions.

Learning resources on MDN

No MDN documentation found. You can search for the feature on MDN. If you believe that MDN has no documentation about this feature, you can open an issue on MDN's GitHub repository.

Browser support