Stay organized with collections
Save and categorize content based on your preferences.
GoogleMobileAds.
Api.
NativeAdOptions
Ad options for configuring the view of native ads.
Summary
Constructors and Destructors
Sets the placement of AdChoices icon (if present).
Image and video aspect ratios.
Public attributes
AdChoicesPlacement
AdChoicesPlacement
AdChoicesPlacement
Sets the placement of AdChoices icon (if present).
Default is TopRightCorner.
MediaAspectRatio
MediaAspectRatio
Image and video aspect ratios.
Default is Unknown.
Public functions
NativeAdOptions
NativeAdOptions
()
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License
, and code samples are licensed under the Apache 2.0 License
. For details, see the Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-20 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-20 UTC."],[],["`NativeAdOptions` configures native ad views. It offers constructors to create new objects, either default or from existing options. Key attributes include setting the `AdChoicesPlacement` to define the AdChoices icon's location (default is TopRightCorner). `MediaAspectRatio` specifies image and video aspect ratios (default is Unknown). `VideoOptions` allows setting the video options. These settings help customize how native ads are displayed.\n"]]