{"id":387073,"date":"2026-10-17T12:03:17","date_gmt":"2026-10-17T12:03:17","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/admin-environment-badge\/"},"modified":"2026-10-17T12:47:31","modified_gmt":"2026-10-17T12:47:31","slug":"abhinavdev-environment-badge","status":"publish","type":"plugin","link":"https:\/\/wordpress.org\/plugins\/abhinavdev-environment-badge\/","author":21095414,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"1.0.0","stable_tag":"1.0.0","tested":"7.1.3","requires":"5.5","requires_php":"7.4","requires_plugins":null,"header_name":"Abhinavdev Environment Badge","header_author":"Abhinav Saxena","header_description":"Displays a prominent, customizable badge in the WordPress Admin Bar indicating the current environment (Local, Staging, Development, Production) to prevent accidental changes on live sites.","assets_banners_color":"121d2a","last_updated":"2026-10-17 12:47:31","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"https:\/\/wordpress.org\/plugins\/abhinavdev-environment-badge\/","header_author_uri":"https:\/\/profiles.wordpress.org\/abhinavdev\/","rating":0,"author_block_rating":0,"active_installs":0,"downloads":64,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.0.0":{"tag":"1.0.0","author":"abhinavdev","date":"2026-10-17 12:47:31","revision":3751923}},"upgrade_notice":[],"ratings":[],"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":3751899,"resolution":"128x128","location":"assets","locale":"","width":128,"height":128},"icon-256x256.png":{"filename":"icon-256x256.png","revision":3751899,"resolution":"256x256","location":"assets","locale":"","width":256,"height":256}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":3751899,"resolution":"1544x500","location":"assets","locale":"","width":1544,"height":500},"banner-772x250.png":{"filename":"banner-772x250.png","revision":3751899,"resolution":"772x250","location":"assets","locale":"","width":772,"height":250}},"assets_blueprints":{},"all_blocks":[],"tagged_versions":["1.0.0"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":3751900,"resolution":"1","location":"assets","locale":"","width":1000,"height":558},"screenshot-2.png":{"filename":"screenshot-2.png","revision":3751900,"resolution":"2","location":"assets","locale":"","width":1000,"height":558}},"screenshots":{"1":"Admin Bar showing the bright environment badge and system info dropdown.","2":"Settings dashboard featuring live preview and color pickers."}},"plugin_section":[],"plugin_tags":[1339,7318,23848,19979,287258],"plugin_category":[],"plugin_contributors":[287259,287260],"plugin_business_model":[],"class_list":["post-387073","plugin","type-plugin","status-publish","hentry","plugin_tags-admin-bar","plugin_tags-environment","plugin_tags-local-development","plugin_tags-staging","plugin_tags-toolbar-badge","plugin_contributors-abhinavdev","plugin_contributors-abhinavsaxena","plugin_committers-abhinavdev"],"banners":{"banner":"https:\/\/ps.w.org\/abhinavdev-environment-badge\/assets\/banner-772x250.png?rev=3751899","banner_2x":"https:\/\/ps.w.org\/abhinavdev-environment-badge\/assets\/banner-1544x500.png?rev=3751899","banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":false,"icon":"https:\/\/ps.w.org\/abhinavdev-environment-badge\/assets\/icon-128x128.png?rev=3751899","icon_2x":"https:\/\/ps.w.org\/abhinavdev-environment-badge\/assets\/icon-256x256.png?rev=3751899","generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/abhinavdev-environment-badge\/assets\/screenshot-1.png?rev=3751900","caption":"Admin Bar showing the bright environment badge and system info dropdown."},{"src":"https:\/\/ps.w.org\/abhinavdev-environment-badge\/assets\/screenshot-2.png?rev=3751900","caption":"Settings dashboard featuring live preview and color pickers."}],"raw_content":"<!--section=description-->\n<p><strong>Abhinavdev Environment Badge<\/strong> is a lightweight, zero-bloat utility plugin created for WordPress developers, agency teams, and site owners.<\/p>\n\n<p>Have you or your clients ever accidentally edited posts, deleted products, or updated theme options on a <strong>Live Production<\/strong> site believing you were safely working on a <strong>Staging<\/strong> or <strong>Local<\/strong> sandbox?<\/p>\n\n<p>This plugin eliminates that risk by injecting an unmistakable, color-coded visual indicator directly into the top WordPress Toolbar (Admin Bar) on both backend and frontend.<\/p>\n\n<h3>Key Features<\/h3>\n\n<ul>\n<li><strong>Intelligent Environment Detection:<\/strong> Automatically identifies your environment using native WordPress <code>wp_get_environment_type()<\/code>, <code>WP_ENVIRONMENT_TYPE<\/code> constants, or domain heuristics (<code>localhost<\/code>, <code>.test<\/code>, <code>.local<\/code>, <code>staging.*<\/code>).<\/li>\n<li><strong>Manual Override &amp; Custom Labels:<\/strong> Need to specify a custom label like \"Client UAT\" or \"Feature Branch\"? Override detection with a single click.<\/li>\n<li><strong>Custom Color Palettes:<\/strong> Full control over background and text colors for each environment using native WordPress color pickers.<\/li>\n<li><strong>Live Settings Preview:<\/strong> See your badge update in real-time right inside the settings dashboard before saving.<\/li>\n<li><strong>System Info Dropdown:<\/strong> Hovering over the badge displays key diagnostic data: Active Environment, WordPress Version, PHP Version, and Host name.<\/li>\n<li><strong>Position Controls:<\/strong> Position the badge on the right or left of the admin bar.<\/li>\n<li><strong>Frontend Visibility Option:<\/strong> Choose whether logged-in administrators see the badge on the frontend or backend only.<\/li>\n<li><strong>100% Native &amp; Lightweight:<\/strong> Zero third-party JavaScript libraries or external CDN dependencies. Clean CSS and native WordPress Settings API.<\/li>\n<\/ul>\n\n<!--section=installation-->\n<ol>\n<li>Upload the <code>abhinavdev-environment-badge<\/code> folder to your <code>\/wp-content\/plugins\/<\/code> directory, or install the <code>.zip<\/code> file via <strong>Plugins &gt; Add New &gt; Upload Plugin<\/strong> in your WordPress admin dashboard.<\/li>\n<li>Activate the plugin through the <strong>Plugins<\/strong> screen in WordPress.<\/li>\n<li>Navigate to <strong>Settings &gt; Environment Badge<\/strong> to customize your environment colors, labels, and display preferences.<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"does%20this%20plugin%20work%20with%20wordpress%20core%27s%20wp_environment_type%3F\"><h3>Does this plugin work with WordPress core's WP_ENVIRONMENT_TYPE?<\/h3><\/dt>\n<dd><p>Yes! If you define <code>define( 'WP_ENVIRONMENT_TYPE', 'staging' );<\/code> inside your <code>wp-config.php<\/code>, the plugin automatically recognizes it and applies the corresponding staging badge.<\/p><\/dd>\n<dt id=\"will%20site%20visitors%20see%20this%20badge%3F\"><h3>Will site visitors see this badge?<\/h3><\/dt>\n<dd><p>No. The badge is strictly rendered inside the WordPress Admin Bar for logged-in users who have administrative or post-editing privileges. Public visitors will never see it.<\/p><\/dd>\n<dt id=\"does%20this%20plugin%20affect%20site%20performance%3F\"><h3>Does this plugin affect site performance?<\/h3><\/dt>\n<dd><p>Not at all. The plugin enqueues less than 2 KB of pure CSS and runs zero external requests or heavy database queries.<\/p><\/dd>\n<dt id=\"can%20i%20use%20custom%20colors%3F\"><h3>Can I use custom colors?<\/h3><\/dt>\n<dd><p>Yes. Under <strong>Settings &gt; Environment Badge<\/strong>, you can use the color pickers to set any hex color for production, staging, development, local, or custom environments.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>1.0.0<\/h4>\n\n<ul>\n<li>Initial public release.<\/li>\n<li>Automatic environment detection via <code>wp_get_environment_type()<\/code> and host matching.<\/li>\n<li>Live preview in settings dashboard.<\/li>\n<li>Customizable color palettes and label text for all environments.<\/li>\n<li>System information dropdown sub-nodes.<\/li>\n<li>Fully compliant with WordPress.org security and coding standards.<\/li>\n<\/ul>","raw_excerpt":"Displays a customizable badge in the WordPress Admin Bar showing your environment (Local, Staging, Production) to avoid errors on live sites.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/387073","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=387073"}],"author":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/abhinavdev"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=387073"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=387073"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=387073"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=387073"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=387073"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=387073"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}