---
name: "removeWeapon"
type: command
status: ok
groups: ["Unit Inventory", "Vehicle Inventory"]
arma3_since: "0.50"
locality: {"argument": "local", "effect": "global", "server_exec": false}
source: https://community.bistudio.com/wiki/removeWeapon
revid: 376459
updated: 2025-10-14T22:27:24Z
---

# removeWeapon

*Command · Unit Inventory, Vehicle Inventory · Arma 3 v0.50 · introduced in Operation Flashpoint v1.00*

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

## Description

Remove weapon from a unit. The unit must be [local](../topics/Multiplayer_Scripting.md#locality) to the computer where command is executed.
For a global version of this command, see [removeWeaponGlobal](../commands/removeWeaponGlobal.md).

> [!NOTE]
> It is possible to create invalid combinations with this command (e.g attempting to remove a weapon that a unit does not possess).
> When doing so, application behaviour is undefined.

## Syntax

### Syntax 1

```sqf
unit removeWeapon weapon
```

**Parameters:**

- `unit`: [Object](../topics/Object.md) - unit or vehicle
- `weapon`: [String](../topics/String.md) - weapon class name

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

### Syntax 2

*since arma3 2.20*

```sqf
object removeWeapon [weapon, autoselect]
```

**Parameters:**

- `object`: [Object](../topics/Object.md) - unit or vehicle
- `weapon`: [String](../topics/String.md) - weapon class name
- `autoselect`: [String](../topics/String.md) - (Optional, default [true](../commands/true.md)) [false](../commands/false.md) to abort weapon autoselection when removing primary weapon.

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

## Examples

### Example 1

```sqf
player removeWeapon "BAF_L85A2_RIS_SUSAT";
```

### Example 2

```sqf
An_2 removeWeapon "M240_veh";
```

## See also

[removeWeaponGlobal](../commands/removeWeaponGlobal.md) · [addWeapon](../commands/addWeapon.md) · [removeAllWeapons](../commands/removeAllWeapons.md)

## Community notes

**zGuba** — 2009-05-27

CTD may occur in certain conditions: when shooter is AI and is currently shooting at target in some proximity (tested with M136 on ACE 1.08 and Compact Fix 1.14H+). Even "dropweapon" action may cause CTD with AI.

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