• /
  • EnglishEspañolFrançais日本語한국어Português
  • Log inStart now

PHP agent installation: Tar file (x86_64, aarch64)

|View as Markdown

You can install New Relic's PHP agent from compressed tar files on any supported operating system on any supported processor architecture. However, for Redhat or CentOS on x86_64 it is more common to use the RPM package. For Ubuntu or Debian on x86_64 it is more common to use the Debian package.

Download the tar distribution

Unlike other installation options, tar archives do not require any special repository setup. All you need to do is download the archive and follow these instructions.

Download the appropriate tar distribution file from download.newrelic.com/php_agent/release/:

  • For Linux with GNU libc (most Linux distributions), download newrelic-php5-X.X.X.X-linux.tar.gz.
  • For Linux with musl libc (Alpine Linux), download newrelic-php5-X.X.X.X-linux-musl.tar.gz.

Tip

The package name for the PHP agent is newrelic-php5. Although the package name references PHP 5, this package works for all supported PHP versions.

Install or update

With tar file installation, the steps for first time installation and for updating are the same. Replace X.X.X.X with the correct New Relic version. To install or update the agent:

  1. Download the appropriate tar file from the New Relic website, and save it to a local disk in a convenient location. Don't use the /tmp folder.

  2. Decompress and extract the archive:

    bash
    $
    gzip -dc newrelic-php5-X.X.X.X-OS.tar.gz | tar xf -
  3. Change to the newly created directory:

    bash
    $
    cd newrelic-php5-X.X.X.X-OS
  4. Run the installation script:

    bash
    $
    ./newrelic-install
  5. Change the default application name to a meaningful name.

  6. Restart your web server (Apache, Nginx, PHP-FPM, etc.).

  7. Wait a few minutes for your application to send data, then check your app's performance in the UI.

Verify the tar file

Starting with PHP agent version 12.13.0.43, you can verify each tar file on the download site with the signing key's fingerprint and the SHA-256 hash of the tar file. Both are published in the release-data directory of the PHP agent's GitHub repository.

To verify a tar file:

  1. Download the tar file, its .asc file (the name of the tar file with .asc added, in the same folder), and the public key. This command prints the URL of the public key and its fingerprint:

    bash
    $
    curl -s https://raw.githubusercontent.com/newrelic/newrelic-php-agent/main/release-data/signing-key-fingerprints.json | jq -r '.keys[] | select(.purpose == "tarball" and .status == "active") | .public_key_url, (.fingerprint | [scan(".{4}")] | join(" "))'
  2. Display the fingerprint of the key file and compare it with the fingerprint from step 1. If they match, import the key:

    bash
    $
    gpg --show-keys --with-fingerprint NEWRELIC_TARBALL_XXXXXXXX.public
    $
    gpg --import NEWRELIC_TARBALL_XXXXXXXX.public
  3. Verify the signature:

    bash
    $
    gpg --verify newrelic-php5-X.X.X.X-OS.tar.gz.asc newrelic-php5-X.X.X.X-OS.tar.gz

    The output must say Good signature, and its Primary key fingerprint line must match the fingerprint from step 1. gpg also prints a warning that the key is not certified with a trusted signature. This is expected.

  4. Compare the SHA-256 hash of the tar file with the one listed for it in tarball-hashes.json. The two hashes must be identical:

    bash
    $
    sha256sum newrelic-php5-X.X.X.X-OS.tar.gz
    $
    curl -s https://raw.githubusercontent.com/newrelic/newrelic-php-agent/main/release-data/tarball-hashes.json | jq -r '.releases[].files[] | select(.filename == "newrelic-php5-X.X.X.X-OS.tar.gz") | .sha256'

Did this doc help with your installation?

Copyright © 2026 New Relic Inc.

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