web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Suggested Answer

Track website visits

(0) ShareShare
ReportReport
Posted on by

Hi!

 

Does anyone know how to embed the Marketing website JavaScript code into google analytics?

Thanks!

I have the same question (0)
  • Camilla Larsson Profile Picture
    235 on at

    Hi,

    When having created a form you can add a marketing webpage on the form hosting tab. That page has a javascript code that you can embedd on your portal. And this page will have a Marketing website form. If you open that page you will see another Javascript code that has the tracking code. Try to embedd this into google analytics.

    Not sure this is what you are locking for. :)

    Kind Regards

    Camilla

  • Community Member Profile Picture
    on at

    Hi,

    Yes, I have the script, but I have no clue where to paste it in google analytics.

    Kind Regards,

    Dave

  • Camilla Larsson Profile Picture
    235 on at

    Ah ok, Sorry I have another guy making that for me so that I am not sure about.

    Camilla

  • cloflyMao Profile Picture
    25,210 on at

    Hi Dave,

    It seems that you've created a marketing form and got generated script under Form hosting tab.

    The script will works for rendering the form and track contact behavior once you paste it on a marketing page.

    As far as I know, Google analytics is another service to track website vistior behavior, it has Java, PHP, and Python version.

    (I'm not sure whether analytics.js would be also part of it.)

    Could you share more details that where do you want to embed script?

    As per my understanding, would your "Google analytics" actually means a web page that has embedded the service?

    We couldn't do any customization on the generated script and integrate it with other service, all track data will be processed to marketing application own back-end.

    Regards,

    Clofly

  • Community Member Profile Picture
    on at

    Hi Clofy,

    pastedimage1578469566180v1.png

    That is the script I have to paste into the google anly. Thats the one the Marketing App generates itself.

  • cloflyMao Profile Picture
    25,210 on at

    Hi Dave,

    As this section said,

    Javascrip-Code is used to track behavior.

    Code in bottom field is used to render form and provides some APIs for form customization.(form load, form submit event etc.)

    If you would just like to render CRM form without track function by CRM, then only copy the bottom code on your web page where Google analytic has been enabled.

    (don't forget to add your own page to whitelist or authencate its domain)

    Regards,

    Clofly

  • ShravanSuri Profile Picture
    1,255 on at

    Hey Dave,

    Could you please provide the scenario that you're trying to achieve here? Why do you want to place a 3rd party javascript code into Google analytics?

    Do you want to see the marketing page opens/visits and insights in your google analytics account (along with the rest of your portal/website)?

    The more details you can provide us, the better our response can be.

    Thank you,

    Shravan

    PM, D365 Marketing

  • Suggested answer
    Vincent Groenheijde Profile Picture
    205 on at

    You can use it via Google Tag Manager (if you use that).

  • Jetj25 Profile Picture
    534 on at

    We did put the code in google tag manager the code has been fired through the tag manager, but it does not detect in marketing app when using  form-capture

  • Kai_1 Profile Picture
    20 on at

    Hello, Did you get it working with Google Tag Manager?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Tom_Gioielli Profile Picture

Tom_Gioielli 170 Super User 2025 Season 2

#2
#ManoVerse Profile Picture

#ManoVerse 70

#3
Jimmy Passeti Profile Picture

Jimmy Passeti 50 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans