---
metadata:
  - name: generator
    content: Diplodoc Platform v5.54.5
alternate:
  - https://divkit.tech/docs/en/concepts/divs/2/div-aspect.md
  - https://divkit.tech/docs/ru/concepts/divs/2/div-aspect.md
  - href: en/concepts/divs/2/div-aspect.md
    type: text/markdown
    title: Markdown version
  - href: ../../../llms.txt
    type: text/markdown
    title: llms.txt
---
> **Documentation Index:** Fetch the complete configuration index at https://divkit.tech/docs/en/llms.txt

# div-aspect
Fixed aspect ratio. The element's height is calculated based on the width, ignoring the `height` value.

## Parameters
| Parameters | Description |
| --- | --- |
| `ratio` | <p>**number**</p><p>Required parameter.</p><p>`height = width / ratio`.</p><p>Restriction for the value `x`: `x > 0`.</p> |

<details>
<summary>JSON</summary>

```json
{
  ratio*: "number"
}
```
</details>
