WP Manifestindependent plugin directory
manifest / developer / wp-environments

WP Environments

Add a color coded background and label to the admin bar to distinguish between environments.

★ 1stars
1release downloads
v1.0.0latest · 5mo ago

Install

Download wp-environments.zip From the v1.0.0 release on GitHub, May 23, 2026

Upload it under Plugins → Add New Plugin → Upload Plugin, then activate.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/gosuperrad/wp-environments/releases/download/v1.0.0/wp-environments.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

This plugin allows you to set up different environments for your WordPress site. It is useful for when you have a development site and a production site, and you want to be able to easily distinguish between environments.

Installation

Composer (recommended)

The plugin isn't published on Packagist, so add it as a VCS repository in your site's composer.json:

"repositories": [
    { "type": "vcs", "url": "https://github.com/gosuperrad/wp-environments" }
]

Then require it:

composer require superrad/wp-environments:^1.0

The plugin pulls in composer/installers, so it lands in your plugins directory automatically — web/app/plugins/wp-environments/ on Bedrock, wp-content/plugins/wp-environments/ otherwise — and resolves the latest v1.x tag. Use dev-main instead of ^1.0 to track the main branch. (This repo is public, so no auth is needed; a private clone would need a GitHub token in auth.json or SSH.)

Manual

  1. Download wp-environments.zip from the latest release.
  2. In the WordPress admin, go to Plugins → Add New → Upload Plugin and upload the zip (or unzip it into wp-content/plugins/).
  3. Activate the plugin through the Plugins menu.

Configure

Set the environment type in wp-config.php:

define( 'WP_ENVIRONMENT_TYPE', 'local' ); // local | development | staging | production

Usage

The plugin will add a colored bar to the top of the admin bar. The color of the bar will depend on the environment type.

The default colors are:

  1. Local:

    • Color: Green
    • Rationale: Local is usually the starting point for most developers, and green is often associated with safety and a starting point. It signifies that changes here don't affect anyone else.
  2. Development:

    • Color: Blue
    • Rationale: Blue is calming and denotes that while it's beyond the local environment, it's a place for testing and iteration without major consequences.
  3. Staging:

    • Color: Purple
    • Rationale: Purple sets staging visibly apart from the other environments. Staging is typically a pre-production environment that mirrors production as closely as possible — the last line of defense before going live — so it gets its own unmistakable color.
  4. Production:

    • Color: Red
    • Rationale: Red typically denotes danger or a need for caution. In the context of web development or software, it indicates that any changes or issues here have real-world consequences for users.

Releases

1 release. Each count is every asset in that release; expand a row for the breakdown.

Tag
Published
Assets
Downloads
v1.0.0 latest
May 23, 2026 5mo ago
wp-environments.zip
1