DEV Community

HarmonyOS
HarmonyOS

Posted on

DevEco Studio 5.1.0: Build and Run Your First HarmonyOS Wearable App on Huawei Watch 5

Read the original article:DevEco Studio 5.1.0: Build and Run Your First HarmonyOS Wearable App on Huawei Watch 5

DevEco Studio with Watch 5

🧭 Introduction

Huawei's new DevEco Studio 5.1.0 offers a powerful development environment for building HarmonyOS applications, including wearables like the Huawei Watch 5. In this guide, we'll walk through:

  • Installing the IDE

  • Creating a simple “Hello, World!” wearable app

  • Running it on Previewer

  • Deploying it to a real Watch 5 device over Wi-Fi

Let's begin.

🛠️ Step 1: Download & Install DevEco Studio 5.1.0

👉 Download DevEco Studio: DevEco Studio Download Page

📘 Installation Guide: Official Installation Documentation

DevEco Studio 5.1.0 comes with built-in ArkTS language support and HarmonyOS templates.

Once installed, log in using your Huawei ID to access device deployment and signing capabilities.

📱 Step 2: Create a “Hello World” Wearable Project
Go to File > New > Create Project
Choose Empty Ability
Set** Device Type **to Wearable

Create New Project Wizard in DevEco Studio

This will generate a basic project with Index.ets as your default UI entry point.

✨ Step 3: Run the App on Previewer

Use DevEco Studio's built-in live previewer to render your layout without a physical device instantly.

Previewer First Run

Let's try and update the message state text in Index.ets like this:

@Entry
@Component
struct Index {
  @State message: string = '👋 Hello, Watch 5!'; // Updated

  build() {
    RelativeContainer() {
      Text(this.message)
        .id('HelloWorld')
        .fontSize($r('app.float.page_text_font_size'))
        .fontWeight(FontWeight.Bold)
        .alignRules({
          center: { anchor: '__container__', align: VerticalAlign.Center },
          middle: { anchor: '__container__', align: HorizontalAlign.Center }
        })
        .onClick(() => {
          this.message = 'Welcome';
        })
    }
    .height('100%')
    .width('100%')
  }
}
Enter fullscreen mode Exit fullscreen mode
Updating message state property in Index.ets for testing Previewer output updates

🖱️ Click the Previewer button to see the result.

Previewer Updated Run

⌚ Step 4: Run on a Physical Huawei Watch (e.g., Watch 5)

✅ A. Connect the Watch via Wi-Fi

  1. Ensure your Computer and Watch 5 are on the same Wi-Fi network.

  2. On the watch, go to:

  • Settings > About > Software Version

  • Tap Build Number several times to enable Developer Options

  1. Enable:
  • HDC debugging

  • Debug via Wi-Fi (Shows IP address and port information)

To connect from your computer:

  • Go to Tools > IP Connection

  • Enter the watch's IP address and port

  • Click the green Connect button

IP Connection Tool Window

🔏 B. Sign the App with Huawei Developer Account

DevEco Studio typically signs the app automatically if you're signed in.

If signing fails, use the manual method:

Manual Signing Steps:

  1. Prepare Signature Files: Signature File Guide

  2. Go to File > Project Structure > Signing Config tab

  3. Follow the instructions in: Configuring Signature Information

Generate Signature Files Build Window

Project Structure Default Signing Configs Window

▶️ Step 5: Deploy the App to Your Watch

  1. Select your connected Watch 5

  2. Click Run > Run 'entry'

  3. DevEco Studio will build and deploy the app

Runnable Devices Menu

Once installed, you should see "Hello, Watch 5!" on your actual watch screen 🎉

✅ Conclusion

DevEco Studio 5.1.0 offers a polished, integrated experience for ArkTS wearable app development.
Whether you're exploring UI layouts or deploying full-featured apps on HarmonyOS, you're just a few steps away from launching on real hardware.

Start simple, test fast, and scale confidently — straight to the wrist.

📚References

(https://forums.developer.huawei.com/forumPortal/en/topic/0201189851517240055?fid=0102647487706140266)

Written by Bilal Basboz

Top comments (0)