New Relic & Magento. Quick start

In this guide, we will show you how to quickly monitor the bottleneck in your code in production mode on Magento.

Why you may need to integrate Magento with New Relic. Possible Cases:

  • You have launched the Magento 2 Store and are not sure that during the development process, you considered all the performance issues that may occur.
  • You have installed third-party extensions that may have performance issues
  • You want to save time on profiling errors and bottlenecks that can happen in production mode of your Magento store.
  • You want to catch mistakes that occur during production, and quickly fix them.

Now let’s proceed to the New Relic installation.

Create New Relic account

Go to the New Relic website and create an account. You can do it here: :

Add new Application

Go to APM (Application Performance Monitoring) -> Applications and choose “Add more”

Application Performance Monitoring


Choose PHP Application

PHP Application


Install NewRelic PHP agent

Follow the instructions:

1. Select the operating system and copy the command to the console to install the NewRelic PHP agent



2. During the installation, you will need to enter a new relic key.

It is available at the first step.


get started with new relic


3. When you start working with the Magento site in the browser, the new relic agent will start sending data to the New Relic service server.

Before doing this, we recommend customized sign your application:

It can be done:

  • In newrelic.ini, the directive is newrelic.appname
  • At the application level (eg .htaccess, virtual host config).

More detailed:

Collecting transaction traces

After the user logs on to the Magento store, New Relic starts collecting data. In the APM -> Applications section, you will see a line with the name of the application.

To receive detailed transactions traces, you need to integrate Magento with New Relic through the API

System -> Configuration -> General -> New Relic Reporting


Clicking on the link with the name of the application, you will see beautiful charts and reports.

The main metrics are the response time from the server and the download time of all the files in the browser.


charts and reports


You can learn each transaction in greater details in the section “Transactions”. Find the longest queries in the “Database” section


Happy debugging and problem solving with Magento & New Relic integration! Our Magento Experts are always ready to help you!

Was this article helpful?
Dislike 0
Views: 84
Valentyn Kubrak

Valentyn KubrakChief Operating Officer

Rate us
Please wait...