honeybadger.js is now universal

Some devs use JavaScript in the browser; some use JavaScript on the server. What if you do both?

For years, Honeybadger has supported client-side JavaScript and Node.js via two separate NPM packages: honeybadger-js (client-side) and honeybadger (Node.js). Today, we're excited to release a new universal package for JavaScript: @honeybadger-io/js.

The following packages are deprecated moving forward:

Use @honeybadger-io/js instead.

Why make this change?

Combining our JavaScript packages means we can share the same core client code while integrating deeply with each environment. The result is less duplication, better consistency, and a more straightforward experience for universal/isomorphic apps that run in multiple environments via Server-side Rendering (SSR).

Do I have to upgrade?

The short answer: You can keep using the old packages (for now), but why would you when upgrading is so easy? See How to upgrade.

The long answer: We will continue to support the old packages, fix bugs, etc., for now. All new development for client-side JavaScript and Node.js will happen on @honeybadger-io/js (the GitHub repo is here).

We plan to deprecate the old packages on NPM in the future to encourage more users to upgrade—if you do it now, you won't have to worry about any of that! :)

How to upgrade

Upgrading to the new @honeybadger-io/js package should take 5 minutes or less for most users. If you have a simple installation, the process has just two steps:

  1. Replace your current package(s) with @honeybadger-io/js, i.e.:

      npm uninstall honeybadger-js honeybadger
      npm install @honeybadger-io/js
  2. Replace any import/require statements that reference the old package(s):

      const Honeybadger = require('@honeybadger-io/js');
      // Or:
      // import Honeybadger from '@honeybadger-io/js';
        apiKey: 'project api key',
        environment: 'production',
        revision: 'git SHA/project version'

If you use a lot of custom configuration, it may take a little bit longer, as there are a few minor breaking changes. For details, check out the complete upgrading guide.

CDN users

If you use our CDN, replace your current script tag with the v3.0 script tag:

<script src="//js.honeybadger.io/v4.2/honeybadger.min.js" type="text/javascript"></script>

Review the upgrading guide for a list of breaking changes.

Reporting bugs

Please report bugs and any other issues you encounter to support@honeybadger.io!

What to do next:
  1. Try Honeybadger for FREE
    Honeybadger helps you find and fix errors before your users can even report them. Get set up in minutes and check monitoring off your to-do list.
    Start free trial
    Easy 5-minute setup — No credit card required
  2. Get the Honeybadger newsletter
    Each month we share news, best practices, and stories from the DevOps & monitoring community—exclusively for developers like you.
    author photo

    Joshua Wood

    Josh started hacking on IRC scripts in the late nineties and has been hacking on computers (and businesses) ever since. As a co-founder of Honeybadger he works on the product, leads marketing and developer relations, and is involved in many open-source projects.

    More articles by Joshua Wood
    Stop wasting time manually checking logs for errors!

    Try the only application health monitoring tool that allows you to track application errors, uptime, and cron jobs in one simple platform.

    • Know when critical errors occur, and which customers are affected.
    • Respond instantly when your systems go down.
    • Improve the health of your systems over time.
    • Fix problems before your customers can report them!

    As developers ourselves, we hated wasting time tracking down errors—so we built the system we always wanted.

    Honeybadger tracks everything you need and nothing you don't, creating one simple solution to keep your application running and error free so you can do what you do best—release new code. Try it free and see for yourself.

    Start free trial
    Simple 5-minute setup — No credit card required

    Learn more

    "We've looked at a lot of error management systems. Honeybadger is head and shoulders above the rest and somehow gets better with every new release."
    — Michael Smith, Cofounder & CTO of YvesBlue

    Honeybadger is trusted by top companies like: