# Opacity
While technically not a transform, opacity can be used to fade elements in and out.
> [!NOTE]
> You also need to apply [`animate-in`][Animate_in] or [`animate-out`][Animate_out] classes respectively.
## `fade-in-*`
| Class |
Styles |
|
`fade-in`
|
```css
--tw-enter-opacity: 0;
```
|
|
`fade-in-`
|
```css
--tw-enter-opacity: calc( / 100);
```
|
|
`fade-in-()`
|
```css
--tw-enter-opacity: var();
```
|
|
`fade-in-[]`
|
```css
--tw-enter-opacity: ;
```
|
## `fade-out-*`
| Class |
Styles |
|
`fade-out`
|
```css
--tw-exit-opacity: 0;
```
|
|
`fade-out-`
|
```css
--tw-exit-opacity: calc( / 100);
```
|
|
`fade-out-()`
|
```css
--tw-exit-opacity: var();
```
|
|
`fade-out-[]`
|
```css
--tw-exit-opacity: ;
```
|
[Animate_in]: ../animations/in-out.md#animate-in
[Animate_out]: ../animations/in-out.md#animate-out