Skip to main content
participantCounts() Returns participant totals for the current call, split between present and hidden participants. Useful when you only need counts — for example, a “people in room” indicator — without needing the full participant objects from participants(). Values are only updated after join() completes. Pre-join steps like preAuth() and startCamera() do not affect counts. The local participant is included in the totals.

Return value

Returns DailyParticipantCounts:
present
number
Participants with hasPresence: true — visible to others and may be able to share media (depending on separate media permissions). These are the participants returned by participants().
hidden
number
Participants with hasPresence: false — not visible to others and unable to share media. Common in large meetings where some participants are passive viewers.

Example

const { present, hidden } = call.participantCounts();
const total = present + hidden;
console.log(`${total} in call (${present} present, ${hidden} hidden)`);

See also