So, I read that Magento 2.3 will be introducing Declarative Database Schema.

Today, when you want to alter the schema of a Magento database, the pattern used to accomplish this is to use the InstallSchema and UpgradeSchema classes where code is written to alter the schema. Magento 2.3 will change the recommended way by implementing a declarative database schema.

Please, could someone help explain what this means and why it's so beneficial. And is this referring to changes to the DB itself or just the scripts used to install and upgrade.



1 Answer 1


I'm going to attempt to answer my own question here based on a post I just read here.

From what I understand... Right now, when a module is developed for Magento 2 it has to be written in a way that can easily invite bugs and complexity.

Common issues include:

  • Having different types of scripts makes the system unstable and difficult
  • Excessive complexity of installation
  • There is no update validation

The upcoming update will allow developers to restructure parts of their modules so that it can be written much clearer.

Potential solutions include

  • Avoids missed or repeated SQL operations
  • Performance improvements
  • Ability to revert to a previous version

This will result in a reduction of potential bugs, easier development and performance improvements.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.