> For a complete index of all SignalWire documentation pages, fetch https://signalwire.com/docs/llms.txt

# selectVideoInputDevice

> Sets the preferred video input device.

```ts
selectVideoInputDevice(device): void
```

Sets the preferred video input device.

## **Parameters**

Device to select. Pass `null` to clear the current selection. See [`MediaDeviceInfo`](https://developer.mozilla.org/en-US/docs/Web/API/MediaDeviceInfo).

## **Returns**

`void`

## **Examples**

```ts
client.selectVideoInputDevice(device);
```

## **See**

* [`videoInputDevices$`](/docs/browser-sdk/v4/reference/signalwire/video-input-devices\$) — list of available cameras.
* [`selectedVideoInputDevice$`](/docs/browser-sdk/v4/reference/signalwire/selected-video-input-device\$) — reactive state.
* [`deviceRecovered$`](/docs/browser-sdk/v4/reference/signalwire/device-recovered\$) — auto-switch events.