> For the complete documentation index, see [llms.txt](https://docs.digit.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.digit.org/platform/guides/developer-guide/ui-developer-guide/digit-ui-components0.2.0/foundation/typography.md).

# Typography

Typography is a crucial part of a design system, ensuring consistency, readability, and usability across different platforms and devices. Good typography rules help present content clearly and efficiently.

## Typefaces (font family)

***

DIGIT Typography uses the typefaces Roboto and Roboto Condensed.

<figure><img src="/files/ocM3NXSx1DWlVTf6XZV2" alt=""><figcaption></figcaption></figure>

## Typography Components

***

### Headings

Headings establish the visual hierarchy of the content, guiding users through structured information. They range from large titles for prominent sections to smaller subheadings for organizations.

| Heading                                                                            | Mobile Scale | Tablet Scale | Desktop Scale |
| ---------------------------------------------------------------------------------- | ------------ | ------------ | ------------- |
| <p><strong>headingXl</strong></p><p>Used for main page titles.</p>                 | 32px         | 36px         | 40px          |
| <p><strong>headingL</strong></p><p>Suitable for section headers.</p>               | 24px         | 28px         | 32px          |
| <p><strong>headingM</strong></p><p>Used for subsections or feature highlights.</p> | 20px         | 22px         | 24px          |
| <p><strong>headingS</strong></p><p>Ideal for smaller titles and labels.</p>        | 16px         | 16px         | 16px          |
| <p><strong>headingXS</strong><br>Used for minor headings and annotations.</p>      | 12px         | 14px         | 14px          |

<figure><img src="/files/fRZOGu2H1mj2fWFD9lUf" alt=""><figcaption></figcaption></figure>

### Body Text

Body text is the primary content in paragraphs, articles, or instructions. It should be readable, well-spaced, and appropriately sized for different devices.

| Body Text                                                                               | Mobile Scale | Tablet Scale | Desktop Scale |
| --------------------------------------------------------------------------------------- | ------------ | ------------ | ------------- |
| <p><strong>bodyL</strong></p><p>Used for general reading content.</p>                   | 16px         | 20px         | 20px          |
| <p><strong>bodyS</strong></p><p>Ideal for supporting information and descriptions.</p>  | 14px         | 16px         | 16px          |
| <p><strong>bodyXS</strong></p><p>Used for less prominent text, such as disclaimers.</p> | 12px         | 14px         | 14px          |

<figure><img src="/files/cQscL2QAKnOrixhJLjH5" alt=""><figcaption></figcaption></figure>

### Caption Text

Captions text provide supplementary information, often appearing in smaller font sizes below the primary content

| Caption Text                                                                        | Mobile Scale | Tablet Scale | Desktop Scale |
| ----------------------------------------------------------------------------------- | ------------ | ------------ | ------------- |
| <p><strong>captionL</strong></p><p>Used for standout short descriptions.</p>        | 24px         | 28px         | 28px          |
| <p><strong>captionM</strong></p><p>Suitable for explanatory notes.</p>              | 20px         | 24px         | 24px          |
| <p><strong>captionS</strong></p><p>Best for minor clarifications and subtitles.</p> | 16px         | 20px         | 20px          |

<figure><img src="/files/QMr8p9Nb0NaayvFZoloF" alt=""><figcaption></figcaption></figure>

### Links

Links are interactive text elements used to navigate or perform actions. They are always underlined to indicate clickability. They all have the same scale across all breakpoints.

| Links                                                            | Scale |
| ---------------------------------------------------------------- | ----- |
| <p><strong>linkL</strong></p><p>Used for large link buttons</p>  | 20px  |
| <p><strong>linkM</strong></p><p>Used for medium link buttons</p> | 16px  |
| <p><strong>linkS</strong></p><p>Used for small link buttons</p>  | 14px  |

<figure><img src="/files/bEQddaVnVGpPnl6evXl9" alt=""><figcaption></figcaption></figure>

### Buttons

Button text is designed to be clear, actionable, and distinguishable from other text elements. It maintains a bold style for better visibility. They all have the same scale across all breakpoints.

| Button                                                             | Scale |
| ------------------------------------------------------------------ | ----- |
| <p><strong>buttonL</strong></p><p>Used for large buttons</p>       | 20px  |
| <p><strong>buttonM</strong></p><p>Used for medium size buttons</p> | 16px  |
| <p><strong>buttonS</strong></p><p>Used for small size buttons</p>  | 14px  |

<figure><img src="/files/FaLKOP8CfX0RjpcsedMw" alt=""><figcaption></figcaption></figure>

## Line Height

***

| <p><strong>Heading And Caption</strong></p><p>Heading and Caption use a 1.14× multiplier for Roboto and Roboto condense.</p> | ![](/files/EQivK3IscIWev0PIyv7d) |
| ---------------------------------------------------------------------------------------------------------------------------- | -------------------------------- |
| <p><strong>Body and Link</strong></p><p>Body and Link use a 1.37× multiplier for Roboto.</p>                                 | ![](/files/WhGb5dh02bpCy6rUI8f9) |

## Usages Guidelines

***

| <p><strong>Use defined font sizes</strong></p><p>Choose from library defined font sizes. By using unique font sizes, you risk upsetting the hierarchy and balance of typography in your product.</p>                                                                                                                                                                                                                                                                                                              | ![](/files/PEoOvrPFzKVDFqvtxTEW) |
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------- |
| <p><strong>Don't use underlines for adding emphasis</strong></p><p>Underlines are reserved for text links only. They should not be used as a way for adding emphasis to words.</p>                                                                                                                                                                                                                                                                                                                                | ![](/files/Fd3qeCP5stBBgEqS4l5Q) |
| <p><strong>Respect capitalization rules</strong></p><p>Use sentence case for all UX content.</p>                                                                                                                                                                                                                                                                                                                                                                                                                  | ![](/files/lniucTPUjqmYniwfYkJP) |
| <p><strong>Use tabular numbers for numerical data</strong></p><p>Numbers within components should be tabular with lining figures. In tables, numbers should be right aligned to make numerical data easier to read and compare.</p>                                                                                                                                                                                                                                                                               | ![](/files/sabtfTz5N54HasKdsxqo) |
| <p><strong>Don't let paragraph widths get too thin</strong></p><p>Paragraphs of text that are too long are difficult to follow, and paragraphs of text that are too thin are difficult to read. Ideally, blocks of text should be roughly 70 characters wide. Be sure to keep them at least between 50 and 120 characters wide.</p>                                                                                                                                                                               | ![](/files/66FZyioF4uiZ5gb9Lruw) |
| <p><strong>Keep content short and to the point</strong></p><p>Keep paragraphs concise. Some users with cognitive disabilities (and even those who don’t) can have a very difficult time reading and comprehending large blocks of text.</p>                                                                                                                                                                                                                                                                       | ![](/files/eXo4sXUSTL54ux14RqLz) |
| <p><strong>Don't use indentation</strong></p><p>Paragraphs of text should not be indented. </p>                                                                                                                                                                                                                                                                                                                                                                                                                   | ![](/files/Z3kBg1L7jsBIa3OtqfAz) |
| <p><strong>Don't fully-justify text</strong></p><p>Do not use fully-justified blocks of text. This adds trapped white space within paragraphs, which makes it harder to read, especially for those with cognitive disabilities or dyslexia. Right alignment (left rag) is also discouraged for paragraphs of text.</p>                                                                                                                                                                                            | ![](/files/dbB3n0kcJu9M43xXhHC6) |
| <p><strong>Typography component pairing</strong></p><p>Heading, body, caption, and link typography components can be paired together in order to create balanced relationships while enforcing hierarchy of content. By default, this can be done by using text block components with the same size.<br><br>Relationships may sometimes need to be more or less pronounced, so in those use cases, it’s acceptable to combine your own selection of sizes as long as you’re maintaining consistent hierarchy.</p> | ![](/files/xn1iqZ06TfZcD09xD8Q3) |

## Change log

| Dates | Number | Note |
| ----- | ------ | ---- |
|       |        |      |
|       |        |      |
|       |        |      |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.digit.org/platform/guides/developer-guide/ui-developer-guide/digit-ui-components0.2.0/foundation/typography.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
