Your data. Anywhere you go.

New Relic for iOS or Android

Download on the App Store    Android App on Google play

New Relic Insights App for iOS

Download on the App Store

Learn more

Close icon

Recommended way to stop New Relic JS injection in AMP pages



We’re using JSP as the rendering mechanism. I see the following two ways to do disable injection in AMP pages.


Here we copy the JS from NR and manually include it on non-AMP pages.


Pls, see “JSP manual instrumentation” on the above page. Here we aren’t copying the JS, but rather we’re calling the APIs given by NR to get the JS injected on all non-AMP pages.

Which one is recommended here? I see both these options are possible with our set up. Just wondering if there is any pros / cons between these?


A post was merged into an existing topic: Stopping NR Javascript injection in AMP pages