Black Lives Matter. Please consider donating to Black Girls Code today.

How do I add Adsense snippet to Dash app?

Trying to incorporate Google Adsense. Saw some forums that had some answers but they are outdated. Anyone have any idea?

I’d use the app.index_string here in: Put the script tag right under the title tag, worked for me.


so I did that but still doesn’t work when I tell adsense I’ve added to my website, did you need to do anything else?

Hmm, that seems to have worked for me. Can you see the script when you inspect your page/is it at the right URL for Adsense?

I was able to get it to work using your suggestion. What I needed to do is make sure the custom html is at the top of the app script.