---
name: "unassignItem"
type: command
status: ok
groups: ["Unit Inventory"]
arma3_since: "0.50"
locality: {"argument": "global", "effect": "global", "server_exec": false}
source: https://community.bistudio.com/wiki/unassignItem
revid: 353052
updated: 2024-03-12T12:31:28Z
---

# unassignItem

*Command · Unit Inventory · Arma 3 v0.50*

Locality: arguments **global** · effect **global**

## Description

Unassigns existing item and tries to put it into inventory. If there is no space in inventory the item simply disappears. See also [unlinkItem](../commands/unlinkItem.md).

## Syntax

```sqf
unit unassignItem item
```

**Parameters:**

- `unit`: [Object](../topics/Object.md)
- `item`: [String](../topics/String.md)

**Returns:** [Nothing](../topics/Nothing.md)

## Examples

### Example 1

```sqf
_bluforUnit unassignItem "NVGoggles";
_bluforUnit removeItem "NVGoggles";
_opforUnit unassignItem "NVGoggles_OPFOR";
_opforUnit removeItem "NVGoggles_OPFOR";
_independentUnit unassignItem "NVGoggles_INDEP";
_independentUnit removeItem "NVGoggles_INDEP";
```

### Example 2

```sqf
{
    _x unassignItem hmd _x; // unassign (not remove) NVGs from all units
} forEach allUnits;
```

## See also

[assignItem](../commands/assignItem.md) · [addItem](../commands/addItem.md) · [removeItem](../commands/removeItem.md) · [linkItem](../commands/linkItem.md) · [unlinkItem](../commands/unlinkItem.md) · [assignedItems](../commands/assignedItems.md) · [removeAllAssignedItems](../commands/removeAllAssignedItems.md)

<sub>Source: [BI Community Wiki — unassignItem](https://community.bistudio.com/wiki/unassignItem) (revision 353052).</sub>
