commands.sh

scrcpy

all

Display and control your Android device on a desktop.

More info →

Options (5)

-S, --turn-screen-offboolean

Turn the device screen off and prevent it from sleeping while mirroring

Example: scrcpy {{[-S|--turn-screen-off]}} {{[-w|--stay-awake]}}
-w, --stay-awakeboolean

Turn the device screen off and prevent it from sleeping while mirroring

Example: scrcpy {{[-S|--turn-screen-off]}} {{[-w|--stay-awake]}}
-s, --serialboolean

Display a mirror of a specific device based on its ID or IP address (find it under the `adb devices` command)

Example: scrcpy {{[-s|--serial]}} {{0123456789abcdef|192.168.0.1:5555}}
-t, --show-touchesboolean

Show touches on physical device

Example: scrcpy {{[-t|--show-touches]}}
-r, --recordboolean

Record display screen

Example: scrcpy {{[-r|--record]}} {{path/to/file.mp4}}

Examples (8)

Display a mirror of a connected device

Turn the device screen off and prevent it from sleeping while mirroring

scrcpy [-S|--turn-screen-off] [-w|--stay-awake]

Display a mirror of a specific device based on its ID or IP address (find it under the `adb devices` command)

scrcpy [-s|--serial] 0123456789abcdef|192.168.0.1:5555

Show touches on physical device

scrcpy [-t|--show-touches]

Record display screen

scrcpy [-r|--record] path/to/file.mp4

Specify the target directory for pushing files to device by drag and drop (non-APK)

scrcpy --push-target path/to/directory

View the phone's camera (requires Android 12 or newer)

scrcpy --video-source camera

Create a Video4Linux2 device from the phone's camera (`v4l2loopback` must be installed)

scrcpy --video-source camera --camera-size 1920x1080 --v4l2-sink /dev/video0 --no-playback
made by @shridhargupta | data from tldr-pages