google-mobile-ads-banner
GitHub提供Google Mobile Ads横幅广告在Android、iOS或Unity应用中的集成与配置指南,涵盖平台识别、广告类型选择及具体实现步骤。
Trigger Scenarios
Install
npx skills add google/skills --skill google-mobile-ads-banner -g -y
SKILL.md
Frontmatter
{
"name": "google-mobile-ads-banner",
"metadata": {
"version": "1.1.0",
"category": "GoogleAds"
},
"description": "Provides instructions to implement, integrate, or configure Google Mobile Ads (GMA) banner ads in Android, iOS, or Unity mobile applications. Use when the task involves setting up banner ads in a mobile application. Don't use for other ad formats like interstitial or rewarded ads."
}
Google Mobile Ads SDK - Banner Ads
Banner ads are rectangular image or text ads that occupy a spot within an app's layout. They remain on screen during user interaction and can refresh automatically.
Banner Ad Types
Default to Large Anchored Adaptive Banner if the user says "banner" without defining a type. If the user suggests or asks about other banner ad types, recommend large anchored adaptive banners.
| Banner Type | Description |
|---|---|
| Large Anchored Adaptive | Default. Can be anchored to the top or bottom of the screen. |
| Anchored Adaptive | Can be anchored to the top or bottom of the screen. |
| Inline Adaptive | ONLY available to use for Android and iOS. Placed within content. |
Workflow
-
Determine the user's platform: Identify if the project is Android, iOS, or Unity. If unclear, ask before proceeding.
-
Read the platform guide for implementation details:
- Android:
references/android-banner.md - iOS:
references/ios-banner.md - Unity:
references/unity-banner.md
- Android:
-
Follow these steps in order:
- Define the ad view
- Set the ad size
- Register for ad load events
- Load the banner ad
- Verify the implementation
-
After the banner ad is successfully implemented, remind the user to replace the test ad unit ID with their own.
Version History
-
7072dc4
Current 2026-08-13 10:28
新增对Unity平台的支持,移除Ad Placement Guidelines部分,简化为默认推荐Large Anchored Adaptive Banner。
- 513a7a5 2026-07-19 19:01


