> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reelevant.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Add to Date

> Add time to a date

## Overview

The `add-to-date` transformation adds a specified amount of time to a date.

## Syntax

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
add-to-date(<date-variable>, <amount-variable>, unit="days")
```

## Parameters

| Parameter         | Type   | Required | Description                                                                                             |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------- |
| `date-variable`   | date   | Yes      | The date to add time to                                                                                 |
| `amount-variable` | number | Yes      | The amount of time to add                                                                               |
| `unit`            | string | No       | Unit of time: `"milliseconds"`, `"seconds"`, `"minutes"`, `"hours"`, `"days"`, `"months"`, or `"years"` |
| `inputLocale`     | string | No       | Locale used to parse the input date: `"pt"`, `"nl"`, `"en"`, `"de"`, `"ja"`, `"zh"`, or `"fr"`          |

## Examples

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
add-to-date(<date-variable>, <amount-variable>, unit="days")
add-to-date(<date-variable>, <amount-variable>, unit="hours", inputLocale="fr")
```
