---
name: "countSide"
type: command
status: ok
groups: ["Sides", "Object Detection"]
arma3_since: "0.50"
locality: {"argument": "global", "effect": null, "server_exec": false}
source: https://community.bistudio.com/wiki/countSide
revid: 378522
updated: 2026-05-04T01:53:42Z
---

# countSide

*Command · Sides, Object Detection · Arma 3 v0.50 · introduced in Operation Flashpoint v1.00*

Locality: arguments **global**

## Description

Returns how many units in the given array belong to given side.

## Syntax

```sqf
side countSide array
```

**Parameters:**

- `side`: [Side](../topics/Side.md)
- `array`: [Array](../topics/Array.md) of [Object](../topics/Object.md)s or [Group](../topics/Group.md)s

  > [!NOTE]
  > If the object in passed array is a [Group](../topics/Group.md), the leader of the group will be counted.

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

## Examples

### Example 1

```sqf
_num = west countSide list _triggerOne;
```

### Example 2

```sqf
_numCivPlayable = civilian countSide playableUnits;
```

## See also

[countFriendly](../commands/countFriendly.md) · [countEnemy](../commands/countEnemy.md) · [countUnknown](../commands/countUnknown.md) · [count](../commands/count.md) · [countType](../commands/countType.md) · [playersNumber](../commands/playersNumber.md) · [units](../commands/units.md) · [allUnits](../commands/allUnits.md)

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