Tổng quan về Dịch vụ Google Play
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
Dịch vụ Google Play hỗ trợ một loạt SDK trên Android để giúp bạn xây dựng ứng dụng, tăng cường khả năng bảo vệ quyền riêng tư và tính bảo mật, tương tác với người dùng cũng như phát triển hoạt động kinh doanh. Các SDK này chỉ yêu cầu một thư viện ứng dụng đơn giản được đưa vào ứng dụng của bạn, như minh hoạ trong hình 1. Khi chạy, thư viện ứng dụng sẽ giao tiếp với một quy trình triển khai đầy đủ đang chạy trong ứng dụng dịch vụ chính của Google Play.
Bằng cách cung cấp các hoạt động triển khai chung ở phía máy khách, Dịch vụ Google Play:
- Giúp tối ưu hoá các tài nguyên trên thiết bị (chẳng hạn như bộ nhớ và dung lượng lưu trữ) để cải thiện chất lượng ứng dụng và trải nghiệm tổng thể của người dùng.
- Nhận các bản cập nhật tự động (không phụ thuộc vào bản cập nhật hệ điều hành, OEM hoặc ứng dụng) để người dùng của bạn nhận được các bản sửa lỗi và cải tiến nhanh hơn.
- Cung cấp khả năng tương thích ngược với Android 6.0 (API cấp 23) và hoạt động trên nhiều hệ số hình dạng, cho phép bạn tiếp cận nhiều người dùng hơn mà không tốn nhiều công sức.
Hình 1. Dịch vụ Google Play nhận các bản cập nhật thường xuyên có chứa các điểm cải tiến và bản sửa lỗi.
Cách hoạt động của Dịch vụ Google Play
SDK
Mỗi SDK các dịch vụ của Google Play đều có một thư viện ứng dụng đơn giản với các API tương tác với một dịch vụ chạy trong ứng dụng Các dịch vụ của Google Play.
Các thư viện này cũng cung cấp các trình trợ giúp để xử lý các vấn đề về thời gian chạy một cách hiệu quả, chẳng hạn như khi một dịch vụ bị thiếu, bị vô hiệu hoá hoặc đã lỗi thời. Khi bạn bật tính năng rút gọn mã, trình tối ưu hoá R8 sẽ giảm thêm tác động của SDK đến kích thước gói bằng cách xoá mã không dùng đến.
Để truy cập vào các tính năng hoặc sản phẩm mới của Dịch vụ Google Play, hãy nâng cấp SDK khi một phiên bản mới được phát hành cho kho lưu trữ Google Maven.
Dịch vụ
Dịch vụ Google Play chứa một tập hợp các dịch vụ cốt lõi chạy ở chế độ nền trên thiết bị và hoạt động trên mọi thiết bị Android được Google chứng nhận.
Các bản cập nhật tự động cho Dịch vụ Google Play được cung cấp độc lập với nhà mạng, hệ điều hành hoặc các bản cập nhật hình ảnh hệ thống của OEM. Nhìn chung, các thiết bị chạy Android 6.0 trở lên sẽ tự động nhận được bản cập nhật, miễn là các thiết bị này đã cài đặt Dịch vụ Google Play và có đủ bộ nhớ. Điều này có nghĩa là người dùng sẽ nhận được các bản cải tiến và bản sửa lỗi nhanh hơn, đồng thời bạn có thể tận dụng các API mới nhất trong khi tiếp cận hầu hết các thiết bị trong hệ sinh thái Android. Các thiết bị cũ hơn Android 6.0 hoặc các thiết bị chưa cài đặt Dịch vụ Google Play đều không được hỗ trợ.
Các bước tiếp theo: thiết lập ứng dụng
Để bắt đầu sử dụng các API Dịch vụ Google Play trong ứng dụng, hãy đọc hướng dẫn thiết lập này.
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-08-31 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-08-31 UTC."],[[["\u003cp\u003eGoogle Play services optimizes app performance and user experience by providing shared, client-side implementations of SDKs, minimizing resource usage.\u003c/p\u003e\n"],["\u003cp\u003eAutomatic updates to Google Play services ensure users receive the latest improvements and bug fixes quickly, independent of OS or device updates.\u003c/p\u003e\n"],["\u003cp\u003eGoogle Play services offers broad compatibility, supporting Android 6.0 (API level 23) and above, various form factors, enabling wider user reach with less development effort.\u003c/p\u003e\n"],["\u003cp\u003eSDKs powered by Google Play services utilize lightweight client libraries, reducing app size and ensuring efficient interactions with Google services.\u003c/p\u003e\n"],["\u003cp\u003eGoogle Play services runs essential Google services in the background on certified Android devices, delivering automatic updates for enhanced functionality and security.\u003c/p\u003e\n"]]],["Google Play services provides lightweight SDK client libraries for Android apps, which interact with shared services on the device. These services optimize device resources, receive automatic updates independent of OS or app updates, and offer backward compatibility to Android 6.0. Developers can update SDKs to access new features through the Google Maven repository. Automatic updates are delivered to devices with Google Play services installed and running Android 6.0 or later. R8 optimizer can reduce the footprint of each SDK.\n"],null,["# Overview of Google Play services\n\n\u003cbr /\u003e\n\nGoogle Play services powers a broad set of SDKs on Android for building\nyour app, enhancing privacy and security, engaging users, and growing your\nbusiness. These SDKs only require a lightweight client library to be\nincluded in your app, as shown in figure 1. At runtime, the client library\ncommunicates with a full implementation running in the main Google\nPlay services application.\n\nBy providing shared, client-side implementations, Google Play services:\n\n- Helps to optimize on-device resources, such as storage and memory, to improve [app quality](https://developer.android.com/quality) and your users' overall experience.\n- Receives automatic updates---independent of OS, OEM, or app updates---so your users receive improvements and bug fixes more quickly.\n- Provides backward compatibility to Android 6.0 (API level 23) and works across various form factors, enabling you to reach more users with less effort.\n\n**Figure 1.** Google Play services receives regular updates that contain\nimprovements and bug fixes.\n\nHow Google Play services works\n------------------------------\n\n### SDKs\n\nEach Google Play services SDK includes a lightweight client library with APIs\nthat interact with a service that runs in the Google Play services application.\nThese libraries also provide helpers to gracefully handle runtime issues, such\nas when a service is missing, disabled, or out-of-date. When you\nenable code shrinking, the\n[R8 optimizer](https://developer.android.com/studio/build/shrink-code)\nfurther reduces the SDK's impact on your package size by removing unused code.\n\nTo access new Google Play services features or products, upgrade the SDK when a\nnew version is [released](/android/guides/releases) to the [Google Maven\nrepository](https://maven.google.com/web/index.html#com.google.android.gms).\n\n### Services\n\nGoogle Play services contains a core set of on-device background services that\nrun on all Google-certified Android devices.\n\nAutomatic updates to Google Play services are delivered independent of carrier,\nOS, or OEM system image updates. In general, devices running Android 6.0 or\nhigher receive updates automatically, provided that these devices have Google\nPlay services installed and sufficient storage available. This means that users\nreceive improvements and bug fixes more quickly, and you can take advantage of\nthe latest APIs while reaching most devices in the Android ecosystem. Devices\nolder than Android 6.0, or devices without Google Play services installed,\naren't supported.\n\nNext steps: set up your app\n---------------------------\n\nTo begin using Google Play services APIs in your app, read this [setup\nguide](/android/guides/setup)."]]