Title: Web Tracking Code
Last modified: October 20, 2016

---

# Web Tracking Code

 *  [brianmckoy](https://wordpress.org/support/users/brianmckoy/)
 * (@brianmckoy)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/web-tracking-code/)
 * Hello,
 * My website is for a sales organization that I run. I have a CRM system set up
   to monitor and track leads and sales and stuff. The CRM has a Webpage Tracker.
   It gave me some code and the instructions were to “Copy this code in to your 
   HTML code after the body tag.” I am not all that savvy when it comes to this 
   stuff and I didn’t want to mess anything up. Can you tell me how I go about entering
   this code and where do I go to enter it. Thanks for your time and help.

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

 *  [ThemeSumo](https://wordpress.org/support/users/themesumo/)
 * (@themesumo)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/web-tracking-code/#post-8335401)
 * You could use a [Child Theme](https://codex.wordpress.org/Child_Themes), copy
   your footer.php file into it and modify that file with your cody directly after
   the _closing body tag_ `</body>`.
 * Or you can add code using a function within your **Child Theme functions.php**
   file, like so:
 *     ```
       function after_closing_body() {
           // Your custom code here
       }
       add_filter( 'wp_footer', 'after_closing_body' );
       ```
   
 * If you simply opened up your active theme footer.php file and just added your
   code after the closing body tag, when you update the theme in the future, your
   custom code changes will be overwritten – this is why it should be done using
   a Child Theme.
 * If you’re using a custom made theme then modifying the _footer.php_ file is perfectly
   fine.
 * Hope this helps.
 *  Thread Starter [brianmckoy](https://wordpress.org/support/users/brianmckoy/)
 * (@brianmckoy)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/web-tracking-code/#post-8335867)
 * could I just add the code after the closing body tag in the footer.php file for
   now and when I update the theme I can just do it again? Thanks.
 *  [ThemeSumo](https://wordpress.org/support/users/themesumo/)
 * (@themesumo)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/web-tracking-code/#post-8335882)
 * If you wish to do so, then yes you can.
 *  [catacaustic](https://wordpress.org/support/users/catacaustic/)
 * (@catacaustic)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/web-tracking-code/#post-8336601)
 * > could I just add the code after the closing body tag in the footer.php file
   > for now and when I update the theme I can just do it again?
 * You can, but it’s not recommended. Mainly because you will forget. 🙂 I know 
   that from experience… (yes, I’ve done that myself many times!). Using a child
   theme will mean that you don’t have to remember anything, and your tracking won’t
   suffer any down time.

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

The topic ‘Web Tracking Code’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 4 replies
 * 3 participants
 * Last reply from: [catacaustic](https://wordpress.org/support/users/catacaustic/)
 * Last activity: [9 years, 5 months ago](https://wordpress.org/support/topic/web-tracking-code/#post-8336601)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
