• EnglishEspañol日本語한국어Português
  • Log inStart now

Instrumented Python packages

This document lists the packages and modules automatically instrumented by the Python agent after you install it. You can also use custom instrumentation if you want to:

  • Disable instrumentation for specific packages or modules if the instrumentation interferes with your app.
  • Instrument a-third party package or module that is not instrumented automatically by the agent.
  • Add more specific instrumentation for your own code, such as to track the time spent in additional functions.

To request built-in instrumentation for additional packages, get support at support.newrelic.com.

Web frameworks

Backend services

Template rendering

GraphQL Frameworks

The Python agent provides insight into your GraphQL application's operations and resolvers and reports GraphQL-specific metrics and span attributes. For more information on transaction naming and other features, please view our GraphQL documentation. As of agent version, the agent supports the following GraphQL frameworks:

Instance details

The agent collects instance details for a variety of databases and database drivers. The ability to view specific instances and the types of database information depends on your Python agent version.

Python agent version or higher supports the following:


Python package name

Minimum package version

Minimum agent version






















To request instance-level information from datastores currently not listed for your agent, get support at support.newrelic.com.

SQL database adapters

For Python DB-API 2.0 compliant modules listed in this section, the Python agent supports:

  • Timing of database queries
  • Capturing SQL for the database query
  • Capturing a stack trace for long database queries
  • MySQL and PostgreSQ only: Capturing explain plans for slow database queries

The Python agent should be able to track database queries for any Python DB-API 2.0 compliant modules. However, the Python agent only officially supports the modules listed in this section.

For the following database adapters, we provides additional instrumentation for functionality outside of the DB-API 2.0 specification, such as shortcut methods to execute queries without creating cursors:

If your database client module is not listed in this section, get support at support.newrelic.com. New Relic Support may be able to suggest a temporary change to your config file to get it working.

NoSQL database clients

Timing of calls made against NoSQL databases are provided for the following client modules.

Elasticsearch clients

Time spent in calls made to Elasticsearch will be listed in both the main overview chart, as well as in the Databases tab in the UI.

Memcache clients

Timing of memcache requests and capture of type of request is provided for the following memcache client modules.

Solr service clients

Timing of Solr service requests and type of request is provided for the following Solr client modules.

Message broker clients

Timing of message broker transactions is provided for the following modules.

External web services

Timing of external web service requests is carried out via the following modules.

Machine learning models and LLMs

Copyright © 2024 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.