Title: Insert tracking code
Last modified: August 19, 2016

---

# Insert tracking code

 *  [renaissance37](https://wordpress.org/support/users/renaissance37/)
 * (@renaissance37)
 * [16 years, 3 months ago](https://wordpress.org/support/topic/insert-tracking-code/)
 * I want to insert the tracking code to track the number of views on my website
   but I am unable to find where the file is that it is referring to. I am supposed
   to insert the tracking code immediately before the </body> tag of each page I
   am planning to track. Right now, that is just my homepage, so where is it I go
   to do this?

Viewing 1 replies (of 1 total)

 *  [Samuel B](https://wordpress.org/support/users/samboll/)
 * (@samboll)
 * [16 years, 3 months ago](https://wordpress.org/support/topic/insert-tracking-code/#post-1384915)
 * in most themes the `</body>` tag is in the theme’s `footer.php` – however this
   would naturally put the code on every page of the site
 * not sure – might work in theme’s `index.php` between
 *     ```
       <?php get_sidebar(); ?>
   
       <?php get_footer(); ?>
       ```
   

Viewing 1 replies (of 1 total)

The topic ‘Insert tracking code’ is closed to new replies.

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 1 reply
 * 2 participants
 * Last reply from: [Samuel B](https://wordpress.org/support/users/samboll/)
 * Last activity: [16 years, 3 months ago](https://wordpress.org/support/topic/insert-tracking-code/#post-1384915)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
