---
schema_version: "1"
id: 0963f6bd9035f55d3dbb640964dfe236375b48de2b0722f8c53f5bfe2a0b6db1
title: decodeURIComponent
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/dataweave/2.4/dw-url-functions-decodeuricomponent.md
canonical_url: https://docs.mulesoft.com/dataweave/2.4/dw-url-functions-decodeuricomponent
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 34bd1ac1ec3a2163f7e9d077b3dd29e8ae9a379efabca38f8bfae076457ebfdc
description: MuleSoft Documentation Site
release: "2.4"
latest: false
---
---
product: DataWeave
version: 2.4
---

# decodeURIComponent

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

## decodeURIComponent(text: String): String

Decodes a Uniform Resource Identifier (URI) component previously created by `encodeURIComponent` or
a similar routine.

For an example, see `encodeURIComponent`.

### Parameters

<table><colgroup><col> <col></colgroup><thead><tr><th>Name</th><th>Description</th></tr></thead><tbody><tr><td><p><code>text</code></p></td><td><p>URI component string.</p></td></tr></tbody></table>

### Example

This example decodes a variety of URI components.

#### Source

```DataWeave
%dw 2.0
import * from dw::core::URL
output application/json
---
{
  "decodeURIComponent": {
    "decodeURIComponent" : decodeURIComponent("%20PATH/%20TO%20/DECODE%20"),
    "decodeURIComponent" : decodeURIComponent("%3B%2C%2F%3F%3A%40%26%3D"),
    "decodeURIComponent" : decodeURIComponent("%2D%5F%2E%21%7E%2A%27%28%29%24"),
  }
}
```

#### Output

```JSON
{
   decodeURIComponent: {
     decodeURIComponent: " PATH/ TO /DECODE ",
     decodeURIComponent: ";,/?:@&=",
    decodeURIComponent: "-_.!~*'()\$"
   }
}
```
