Search overlay panel for performing site-wide searches

Build Your Next Big Thing on Heroku. Sign Up Now!

Modernizing the Command Line: Heroku CLI v11

Heroku CLI v11 is now available. This release represents the most significant architectural overhaul in years, completing our migration to ECMAScript Modules (ESM) and oclif v4. This modernization brings faster performance, a new semantic color system, and aligns the CLI with modern JavaScript standards.
While v11 introduces breaking changes to legacy namespaces, the benefits are substantial: better performance, improved maintainability, and enhanced usability that simplifies how you manage Heroku resources from the command line.

Modern architecture built for performance and usability

Faster execution via ECMAScript Modules (ESM)

The transition to a full ESM-first architecture is the core of v11. By converting every command, library, and test from CommonJS to ESM, we’ve unlocked significant performance gains:

  • Superior tree-shaking: Reduced bundle sizes lead to a leaner installation and faster updates.
  • Faster command execution: Optimized module loading streamlines the internal execution path.
  • Modern ecosystem alignment: The CLI now mirrors the standards of modern JavaScript, simplifying long-term maintenance.

Streamlined performance with Open CLI Framework (oclif) v4

We’ve jumped two major versions to oclif v4, bringing the CLI in line with the latest standards of the Open CLI Framework. This transition delivers:

  • Faster command loading: Improved manifest caching ensures the CLI doesn’t have to parse every command for every interaction, making the experience significantly faster.
  • Seamless interoperability: Version 11 ensures smooth compatibility between CommonJS and ESM plugins, allowing for a more flexible developer experience.
  • Modular code organization: The upgrade to oclif v4 enables granular imports, leading to a leaner and more maintainable codebase.

To support these changes, we’ve also simplified our build system—migrating from Yarn to npm and removing the monorepo structure in favor of a single, more maintainable package.

Enhanced visual experience

Usability in v11 extends to how you interact with and interpret terminal data. The CLI’s visual output is now more intuitive, customizable, and accessible:

  • Consistent semantic colors: Common Heroku resources, success, warning, and error messages now follow a unified color palette, making it easier to identify critical information at a glance.
  • Modern theme support: With Version 11, the Heroku CLI is now themeable, allowing for a more modern and readable visual experience. You can also manually opt for a basic ANSI color scheme by setting the HEROKU_THEME=simple env var.
  • Global accessibility: Version 11 supports disabling colors entirely by setting the NO_COLOR=true env var for users with visual impairments or those who prefer plain-text logging.

Node.js 22 support

The Heroku CLI v11 ships with Node.js 22 while maintaining Node.js 20 compatibility, providing several key benefits:

  • Modern runtime access: Users can now leverage the latest JavaScript features and performance improvements provided by the Node.js 22 runtime.
  • Latest standard alignment: The update ensures the CLI remains current with the evolving JavaScript ecosystem.
  • Performance-first foundation: Supporting the latest LTS version of Node.js is essential for delivering the performance gains of our new ESM-first architecture.

New commands for modern Heroku workflows

We have also focused on the day-to-day developer experience. These updates refine how you interact with your Heroku resources and make it easier to discover the tools you need:

  • Unified data maintenance: The heroku data:maintenance:* commands are now built into the core CLI. Note that legacy heroku pg:maintenance and heroku redis:maintenance commands have been deprecated.
  • Fast command discovery: Can’t remember a command name? heroku search helps you find it fast.
  • Global prompt support: The --prompt flag is now available globally and appears in help text for all commands that support it.
  • Streamlined REPL invocation: Access to REPL is now accessible via heroku repl and included in our CLI documentation and help text. Try it out!

Transitioning to Heroku CLI v11

To support this new architecture, v11 includes a few updates to how certain commands and outputs behave. While these represent a shift from legacy versions, they are designed to make your workflow cleaner and more consistent:

  • Output formatting: CLI output format has changed in v11, with the most visible changes in table formatting.
  • AI plugin: To keep the core installation lean and fast, the heroku-cli-plugin-ai is now an optional installation rather than being bundled by default.
  • Unified maintenance commands: We’ve simplified data management by moving maintenance tasks into the core data:maintenance:* namespace. This replaces the legacy pg:maintenance and redis:maintenance commands with a single, intuitive workflow.

A modernized CLI for a modern ecosystem

Heroku CLI v11 is a complete technical modernization designed to grow with the JavaScript ecosystem, and represents a major investment in the CLI’s future. By modernizing our architecture with ESM and oclif v4, we’ve built a faster, more maintainable foundation that will enable us to ship features more quickly while improving the developer experience.
Upgrade today or visit the installation guide. For a full list of updates, check out the CLI changelog. As always, we welcome your feedback as we continue to improve the developer experience.

Ready to Get Started?

Stay focused on building great data-driven applications and let Heroku tackle the rest.

Talk to A Heroku Rep   Sign Up Now

More from the Author
Heroku Staff

Browse the archives for News or all blogs. Subscribe to the RSS feed for News or all blogs.