Create and run your first Wear OS app

This page provides a guide for you to build your first app for Wear OS, using a template from Android Studio. The app showcases the different ways to view information at a glance on Wear OS devices, and introduces some best practices for developing apps on the platform.

This guide builds upon some prior knowledge about the Android platform and the Android Studio IDE. If you're completely new to Android, create an app using this codelab. To learn more about Android Studio's capabilities, visit the Meet Android Studio page.

Create a Wear OS app

After you download and install the latest version of Android Studio, complete the "new project" wizard:

  1. Open Android Studio, and then go to File > New > New Project. The New Project window appears.
  2. In the Templates pane, select Wear OS. Then, in the main pane, select Empty Wear App.
  3. Name your project, and then click Finish. Android Studio downloads the necessary dependencies and builds your project.

You're now ready to run your first app on Wear OS.

Run an app on the emulator

The easiest way to run your first Wear OS app is to configure an emulator.

Configure an emulator

To configure an emulator in Android Studio, complete the following steps:

  1. In the SDK Manager, Open the SDK Tools tab. Confirm that you have the latest version of Android SDK Platform-Tools. Close the SDK Manager.
  2. Go to Tools > Device Manager.
  3. Select Create (+). The Virtual Device Configuration wizard appears.
  4. In the Category pane, select Wear OS and choose a hardware profile, such as Wear OS Small Round. Click Next.
  5. Unless you need specific customizations, keep the default settings on this screen; the latest API and system image should already be selected. Click Finish.

For more information about using emulators, see the guide about how to run apps on the Android Emulator.

Open the app in the emulator

  1. Find the Run Widget in the main toolbar. Select the emulator you created from the device drop-down menu, then click the Run button to launch the app.
  2. After a few moments, you should see a "Hello..." message in the emulator.

Run an app on a physical watch (optional)

Running and debugging your app on an actual watch lets you better evaluate the total user experience. This is particularly important if your app relies on specific hardware, such as sensors or a GPU.

To run an app on a physical watch, prepare the device for testing, and then connect it to your development machine.

Prepare watch for testing

To prepare your watch for testing, enable ADB debugging by completing the following steps.

  1. On the watch, open the Settings menu.
  2. Go to the bottom of the menu. If no Developer options item appears, complete the following sub-steps. Otherwise, continue to the next step.
    1. Tap System > About or System > About > Versions.
    2. Find the Build number item and tap it seven times. If your watch is protected by a PIN or pattern, enter it when prompted to do so.
  3. From the Settings menu, tap Developer options.
  4. Enable the ADB debugging option.

For more information, see Configure on-device developer options.

Connect watch to development machine

Some watches let you connect over USB. Others require a wireless connection.

Set up a wired connection over USB

Connect the watch using the following steps:

  1. Using a USB cable, connect the watch to your development machine.
  2. On the watch, enable Always allow from this computer, and then tap OK.

Set up a wireless connection

If it's not possible to debug your watch over USB port, see Connect to your device using Wi-Fi

Open the app on the watch

  1. In the Run Widget, use the device dropdown to select your physical device.
  2. Click the Run button in the Run Widget (part of the main toolbar).
  3. After a few moments, you should see a "Hello..." message on your device.