Hi,
Thank you for reaching out to the IMA SDK Forum.
It appears that you have already followed the implementation in the forum thread you shared which should be the right approach. Please note that as per this documentation (https://developers.google.com/interactive-media-ads/docs/sdks/html5/client-side/reference/js/google.ima.AdDisplayContainer) when an instance of Class: AdDisplayContainer is created, it creates an IFRAME in the containerElement and loads the SDK core. This IFRAME must be preserved in order for the SDK to function properly. Once all ads have been played and the SDK is no longer needed, use the destroy() method to unload the SDK. This method destroys internal state and previously created DOM elements. The IMA SDK will be unloaded and no further calls to any APIs should be made.
For us to further investigate and provide more appropriate guidance, could you share with us the following information?
You may send the requested details privately via the "Reply To Author" button or with the below process.
If the file(s) you are looking to share are less than 25mb in total you can attach them to this case on your next reply. If you are having trouble attaching your file to this case or if your file(s) are larger than 25mb, you can share your files with me by performing the following steps:
1. Navigate to
2. Fill out all fields, and attach your file(s).
3. Please reply back on this thread when you have uploaded your file(s). Please do not share this link.
Reference Link:
![]() |
IMA SDK Team |
2. Fill out all fields, and attach your file(s).
3. Please reply back on this thread when you have uploaded your file(s). Please do not share this link.
![]() |
IMA SDK Team |
Hi,
Thank you for providing the requested information.
As mentioned, once all ads have been played and the SDK is no longer needed, you can use the destroy() method to unload the SDK. You should also call the contentComplete() on your AdsLoader before destroying it. You can refer to the SDK architecture here: https://developers.google.com/interactive-media-ads/docs/sdks/html5/client-side/architecture
However, please note that the IMA SDK can only control the ad player, if there is still content playing on your video player then the mediacontroller will persist, as also observed on our sample app that the mediacontroller disappears once the content has finished playing.
Let me know if you have any questions.
1. Navigate to
https://docs.google.com/forms/d/e/1FAIpQLSfkAiXMeYP-fw1W3Z-tT9uwmATEKO5X6S-th0gR2ezdKaaqfg/viewform?usp=pp_url&entry.400550049=IMA+SDK&entry.460850823=5004Q00002mXrmAQAS&entry.80707362=001860922. Fill out all fields, and attach your file(s).
3. Please reply back on this thread when you have uploaded your file(s). Please do not share this link.
![]() |
IMA SDK Team |