# Extract IP addresses

Extracts all IPv4 and IPv6 addresses. Warning: Given a string `710.65.0.456`, this will match `10.65.0.45` so always check the original input! Extract IP addresses lives in the **Extractors** category of the `fx` menu.

## Parameters

| Parameter                   | Type    | Required | Default | Description                                            |
| --------------------------- | ------- | -------- | ------- | ------------------------------------------------------ |
| Input                       | string  | yes      | —       | Value to transform. Previous step output or a literal. |
| IPv4                        | boolean | no       | `true`  | Enabled by default.                                    |
| IPv6                        | boolean | no       | `false` | Disabled by default.                                   |
| Remove local IPv4 addresses | boolean | no       | `false` | Disabled by default.                                   |
| Display total               | boolean | no       | `false` | Disabled by default.                                   |
| Sort                        | boolean | no       | `false` | Disabled by default.                                   |
| Unique                      | boolean | no       | `false` | Disabled by default.                                   |

`Input` is the primary value (previous step output or a literal).

## Returned value

| Type     | Description                                        |
| -------- | -------------------------------------------------- |
| `string` | Result of the Extract IP addresses transformation. |

## Example

<details>
<summary>Run Extract IP addresses</summary>

Extracts all IPv4 and IPv6 addresses. Adjust optional parameters when the defaults do not match your payload.

1. Set **Input** to the value to transform (previous step output or a literal).

2. Review **IPv4**, **IPv6**, **Remove local IPv4 addresses**, **Display total**, **Sort**, and other options and keep defaults unless your format requires otherwise.

3. Confirm **Output value** shows the transformed result.

</details>
