---
title: Environments
description: Configure environment-specific error tracking settings for Ruby applications across development, staging, and production.
url: https://docs.honeybadger.io/lib/ruby/errors/environments/
---

In Honeybadger, errors are grouped by the environment they belong to. You don’t have to set an environment, but it can be useful if you’re running different versions of your app: for instance, you may have a “production” and a “staging” environment.

Our integrations typically set the environment automatically if your framework has an environment (such as `Rails.env`). To set the environment manually, set the `env` configuration option:

```yaml
---
api_key: "your-api-key"
env: "production"
```

Another option for configuring the environment that gets reported to Honyebadger is to set the `HONEYBADGER_ENV` environment variable. If this variable is set, its value will override the `RAILS_ENV` variable.

## Development environments

Some environments should usually not report errors at all, such as when you are developing on your local machine or running your test suite (locally or in CI). The *honeybadger* gem has an internal list of environment names which it considers development environments:

```plaintext
development
test
cucumber
```

Honeybadger **does not** report errors in these environments unless you explicitly enable data reporting:

```yaml
---
api_key: "your-api-key"
report_data: true
```

---

## Try Honeybadger for FREE

Intelligent logging, error tracking, and Just Enough APM™ in one dev-friendly platform. Find and fix problems before users notice.

[Start free trial](https://app.honeybadger.io/users/sign_up)

[See plans and pricing](https://www.honeybadger.io/plans/)
