---
schema_version: "1"
id: f0c2ef1a3139ff81c1b7c6e99d0d244e1459f3b0feb43d73fd8455c46ae75464
title: random
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/dataweave/latest/dw-core-functions-random.md
canonical_url: https://docs.mulesoft.com/dataweave/latest/dw-core-functions-random
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 7765046f9876514f27ffd412c3c2e10f17562983fc0c285b13f7f9bdfa73f24e
description: MuleSoft Documentation Site
release: "2.13"
latest: true
---
---
product: DataWeave
version: 2.13
is-latest-version: true
---

# random

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

## random(): Number

Returns a pseudo-random number greater than or equal to `0.0` and less than `1.0`.

### Example

This example generates a pseudo-random number and multiplies it by 1000.

#### Source

```DataWeave
%dw 2.0
output application/json
---
{ price: random() * 1000 }
```

#### Output

```JSON
{ "price": 65.02770292248383 }
```
