스마트 배너
스마트 배너는 다양한 기기에서 화면 크기와 방향에 관계없이 화면 너비의 배너 광고를 렌더링하는 광고 단위입니다. 스마트 배너는 현재 방향에서 기기의 너비를 감지하여 그 크기에 맞춰 광고 뷰를 만듭니다.
스마트 배너에서는 3가지 광고 높이가 구현됩니다.
광고 높이 |
화면 높이 |
32 dp |
≤ 400 dp |
50 dp |
> 400dp 및 ≤ 720dp |
90 dp |
> 720 dp |
일반적으로 휴대전화의 스마트 배너는 세로 50dp, 가로 32dp입니다. 태블릿의 경우 일반적으로 높이는 두 방향 모두에서 90dp입니다.
이미지 광고가 할당된 전체 공간을 차지할 만큼 크지 않은 경우에는 이미지가 중앙에 배치되고 양쪽 공간이 채워집니다.

XML에서 스마트 배너를 사용하려면 광고 크기에 SMART_BANNER
상수를 지정하고 AdView
의 너비를 match_parent
로 설정하세요. 예를 들면 다음과 같습니다.
<com.google.android.gms.ads.admanager.AdManagerAdView
xmlns:ads="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
ads:adSize="SMART_BANNER"
ads:adUnitId="ca-app-pub-3940256099942544/6300978111">
</com.google.android.gms.ads.admanager.AdManagerAdView>
스마트 배너를 프로그래매틱 방식으로 만들려면 AdSize.SMART_BANNER
를 광고 크기로 사용합니다.
AdManagerAdView adView = new AdManagerAdView(this);
adView.setAdSizes(AdSize.SMART_BANNER);
val adView = AdManagerAdView(this)
adView.adSizes = AdSize.SMART_BANNER
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2025-02-25(UTC)
[null,null,["최종 업데이트: 2025-02-25(UTC)"],[[["Smart Banners are responsive ad units that automatically adjust their size to fit the width of the device screen."],["Smart Banners have three possible ad heights (32dp, 50dp, 90dp) depending on the screen height of the device."],["When using Smart Banners, specify `SMART_BANNER` as the `adSize` and set the `AdView` width to `match_parent`."],["Consider using newer adaptive banners instead of Smart Banners for enhanced functionality."]]],["Smart Banners display screen-width ads, adapting to device size and orientation. They use three ad heights: 32 dp (≤ 400 dp screen height), 50 dp (\u003e 400 dp and ≤ 720 dp), and 90 dp (\u003e 720 dp). To implement in XML, set `adSize` to `SMART_BANNER` and `AdView` width to `match_parent`. Programmatically, utilize `AdSize.SMART_BANNER`. Image ads are centered when smaller than the space. The content suggests using adaptive banners instead.\n"]]