Default mode

The default mode enables you to deploy the Commerce application on a single server without changing any settings. However, default mode is not optimized for production because of the adverse performance impact of static files. Creating static files and caching them has a greater performance impact than generating them using the static files creation tool.

In default mode:

  • Exceptions are written to log files instead of display
  • Static view files are cached
  • Hides custom X-Magento-* HTTP request and response headers

Commerce operates in default mode if no other mode is specified.

Developer mode

The developer mode is recommended for extending and customizing the Commerce application. Static view files are not cached, but written to the pub/static directory on demand.

In developer mode:

  • Enables automatic code compilation and enhanced debugging
  • Uncaught exceptions display in the browser
  • System logging in var/report is verbose
  • An exception is thrown in the error handler, rather than being logged
  • An exception is thrown when an event subscriber cannot be invoked
  • Shows custom X-Magento-* HTTP request and response headers
NOTE
This mode is not supported in the Adobe Commerce Cloud environment and Adobe Commerce Support is unable to facilitate changing the application mode.

Production mode

The production mode is best for deploying the Commerce application on a production system. After optimizing the server environment, such as the database and web server, you should run the static view files deployment tool to write static view files to the pub/static directory. This improves performance by providing all necessary static files at deployment instead of forcing the Commerce application to dynamically locate and copy (materialize) static files on demand during run time.

Some fields, such as the Advanced and Developer system configuration sections in the Admin, are not available in production mode. For example, you cannot enable or disable cache types using the Admin. You can enable and disable cache types only using the command line.

In production mode:

  • Static view files are served from the cache only
  • Errors and exceptions are logged to the file system and are never displayed to the user
  • Some configuration fields in the Admin are not available