Title: adsense code and google analytics code in header.php not showing
Last modified: February 7, 2018

---

# adsense code and google analytics code in header.php not showing

 *  [Jeffrey](https://wordpress.org/support/users/zeroandone/)
 * (@zeroandone)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/adsense-code-and-google-analytics-code-in-header-php-not-showing/)
 * I manually added my Adsense code and Google Analytics code in the theme’s header.
   php file, and they were saved correctly, but when I check my site, no ads showed.
   After checking the page source, I realized that no code was showing. When I switched
   to Twenty Seventeen theme and add code in the header.php, it worked.

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Deb Shadovitz](https://wordpress.org/support/users/debshadovitz/)
 * (@debshadovitz)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/adsense-code-and-google-analytics-code-in-header-php-not-showing/#post-9949364)
 * I have been wanting to post something along the same lines.
    Many pros refer 
   to putting this code in header.php. However, using the amazing Childify plugin,
   my child themes don’t get a header.php document.
 * I’m about to post this as its own post but this may help you too because you 
   should always be working in a Child Theme.
 *  Thread Starter [Jeffrey](https://wordpress.org/support/users/zeroandone/)
 * (@zeroandone)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/adsense-code-and-google-analytics-code-in-header-php-not-showing/#post-9949450)
 * I installed Chidify Me, but somehow it didn’t create a child theme. I clicked
   Childify Me button, then gave a name and clicked Save. Nothing happened.
 * Anyway, I understand I should be working with the child theme, but I have been
   editing header.php for a while and never had problem before until now. I wonder
   why.
 *  Thread Starter [Jeffrey](https://wordpress.org/support/users/zeroandone/)
 * (@zeroandone)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/adsense-code-and-google-analytics-code-in-header-php-not-showing/#post-9970470)
 * Just updated to 4.0.18 but the problems still exists.
 * Google Analytics and AdSense code added in header.php are not showing up in page.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘adsense code and google analytics code in header.php not showing’ is 
closed to new replies.

 * ![](https://i0.wp.com/themes.svn.wordpress.org/customizr/4.4.24/screenshot.png)
 * Customizr
 * [Support Threads](https://wordpress.org/support/theme/customizr/)
 * [Active Topics](https://wordpress.org/support/theme/customizr/active/)
 * [Unresolved Topics](https://wordpress.org/support/theme/customizr/unresolved/)
 * [Reviews](https://wordpress.org/support/theme/customizr/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Jeffrey](https://wordpress.org/support/users/zeroandone/)
 * Last activity: [8 years, 4 months ago](https://wordpress.org/support/topic/adsense-code-and-google-analytics-code-in-header-php-not-showing/#post-9970470)
 * Status: not resolved