使用者查看手錶時,最先看到的就是錶面,因此錶面是 Wear OS 上使用率最高的介面。使用者會根據自己的風格和需求,透過錶面打造個人專屬的智慧手錶,並快速掌握資訊。
目標對象
全新的錶面格式 (WFF) 讓錶面建構作業更加輕鬆。我們與 Samsung 合作推出了 Watch Face Studio,這是一種所見即所得的工具,可讓您直接設計錶面。
如果您想手動管理手錶設定,也可以使用 XML 定義錶面。這些指南適用於使用 XML 或建構自訂工具來使用錶面格式建立錶面的開發人員。Android Studio 也支援使用錶面格式建構及執行錶面。
錶面格式是 Google 與 Samsung 合作開發的宣告式 XML 格式,可用於設定錶面的外觀和行為。與其他錶面 API 不同,錶面格式只需要資源和宣告式指示,不像 APK 必須包含用於轉譯錶面的程式碼。Wear OS 平台會負責轉譯錶面所需的邏輯,讓您可以專注於實現創意構想,而不必在程式碼最佳化或電池效能方面多費心思。
相較於使用舊版 Jetpack Watch Face 程式庫建構的錶面,以這個新格式建構錶面可減少維護和更新的需求。舉例來說,您無需更新錶面,即可提高效能或減少電池耗電量,甚至取得最新的錯誤修正項目。
關於格式
錶面格式 (WFF) 錶面的核心是一項定義錶面版面配置和行為的文件。本文件採用 XML 編寫,符合 WFF 規格。
Wear OS 系統包含錶面轉譯器元件。這個元件會剖析 WFF XML 文件,並根據該文件算繪錶面。系統會視需要擷取圖片和字型等其他資源。
[null,null,["上次更新時間:2025-07-27 (世界標準時間)。"],[],[],null,["# Watch Face Format\n\n**Note:** The [Watch Face Format](/training/wearables/wff) is\nrequired for watch faces to be installed on devices with Wear OS 5 or later\npre-installed and for all new watch faces published on Google Play.\n\nStarting in January 2026, the Watch Face Format will be required for watch\nfaces to be installed on all Wear OS devices.\n\nLearn more about the user-facing changes in this\n[Help Center\narticle](https://support.google.com/wearos/thread/284572445). \n\nA watch face is the first thing a user sees when they look at their watch,\nmaking it the most frequently used surface of Wear OS. Users rely on watch faces\nto customize their watches to suit their style and provide quick information at\na glance.\n\nAudience\n--------\n\nOur new Watch Face format (WFF) makes it easier than ever to build a watch face.\nIn partnership with Samsung, we have released [Watch Face\nStudio](https://developer.samsung.com/watch-face-studio/overview.html), a What-You-See-Is-What-You-Get style tool, that lets\nyou design the watch face directly.\n\nIf you prefer to manage your watch configuration manually, you can also define\nwatch faces using XML. These guides target developers who use XML, or who build\ncustom tools to create watch faces using Watch Face Format. Android Studio also\nincludes support for building and running watch faces that use Watch Face\nFormat.\n\nCreated in partnership with Samsung, the Watch Face Format is a declarative XML\nformat to configure the appearance and behavior of watch faces. Unlike other\nwatch face APIs, where your APK must include the code to render the watch face,\nthe Watch Face Format only requires resources and declarative instructions. The\nWear OS platform handles the logic needed to render the watch face so you can\nfocus on your creative ideas, rather than code optimizations or battery\nperformance.\n\nWatch faces built with this new format require less maintenance and\nfewer updates than those built using the legacy Jetpack Watch Face libraries.\nFor example, you don't need to update your watch face to benefit from\nimprovements in performance or battery consumption, or to get the latest bug\nfixes.\n\nAbout the format\n----------------\n\nAt the heart of a Watch Face Format (WFF) watch face is a document that defines\nthe layout and behavior of the watch face. This document is written in XML,\nconforming to the WFF specification.\n\nThe Wear OS system includes a watch face renderer component. This component\nparses your WFF XML document and renders a watch face from it. Other resources,\nsuch as images and fonts, are pulled in as necessary.\n\nThis approach means you only need to spend time describing how the watch\nface should look, and Wear OS handles all of the code for drawing the watch\nface.\n\nTo deploy a Watch Face Format watch face to a device, package the XML document\nin a standard AAB or APK package.\n\nThe following diagram shows an overview of the approach:\n\nVersioning in WFF\n-----------------\n\nAs WFF evolves, new features are added, represented by new elements,\nattributes, data sources, etc. in the format.\n\nFor example, WFF version 2 introduced Weather support as a data source, which\nis not available in WFF version 1.\n\nWhen designing your watch face, be aware of which features you\nwant to use and their version availability. The reference guide marks\nall features with their availability.\n\nEach version of WFF aligns with a Wear OS release:\n\n| WFF version | Minimum Wear OS version | Minimum API level |\n|-------------|-------------------------|-------------------|\n| 1 | 4 | 33 |\n| 2 | 5 | 34 |\n| 3 | 5.1 | 35 |\n| 4 | 6 | 36 |\n\n[See this guidance](/training/wearables/wff/setup#declare-wff-use) for configuring your `AndroidManifest.xml` and Gradle\nbuild file appropriately.\n\nLearn more\n----------\n\nLearn more about the Watch Face Format in these guides:\n\n- [Available features](/training/wearables/wff/features): Explore the watch face capabilities that each version of Watch Face Format supports.\n- [Design guidelines](/design/ui/wear/guides/surfaces/watch-faces): Learn best practices for your watch face's layout and user experience.\n- [Setup](/training/wearables/wff/setup): Configure an Android App Bundle that supports the Watch Face Format.\n- [GitHub samples](https://github.com/android/wear-os-samples/tree/main/WatchFaceFormat): Get started by building sample watch faces and deploying them on the Wear OS emulator or your physical device.\n- [Optimize memory usage](/training/wearables/wff/memory-usage): Learn how to configure your watch face so the system consumes as little memory as possible when rendering your watch face.\n- [XML reference](/training/wearables/wff/watch-face): Explore the individual elements that are parts of a Watch Face Format file. The root element is always `WatchFace`. Note: To view features from a specific Watch Face Format version in the XML reference, check that the appropriate version button is selected at the top of the documentation page.\n- [Publishing guide](https://support.google.com/googleplay/android-developer/answer/13560201): Learn how to publish and monetize your watch face through the Play Store and alternative methods.\n- [WFF and memory validator](https://github.com/google/watchface): Use these open source tools to check your Watch Face Format file for errors and confirm acceptable memory usage before submitting to Google Play."]]