## formatDate() function [​](/content/docs/sdk/core.formatdate#formatdate-function "Direct link to formatDate(/index.html) function")

Formats a FHIR date string as a human readable string. Handles missing values and invalid dates.

**Signature:**

```typescript
export declare function formatDate(date: string | undefined, locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions): string;
```

## Parameters [​](/content/docs/sdk/core.formatdate#parameters "Direct link to Parameters"/index.html)

| Parameter | Type | Description |
| --- | --- | --- |
| date | string \| undefined | The date to format. |
| locales | Intl.LocalesArgument | _(Optional)_ Optional locales. |
| options | Intl.DateTimeFormatOptions | _(Optional)_ Optional date format options. |

**Returns:**

string

The formatted date string.

- [formatDate() function](/content/docs/sdk/core.formatdate#formatdate-function/index.html)
- [Parameters](/content/docs/sdk/core.formatdate#parameters/index.html)
