This is a beta release of documentation for Magento 2.4, published for previewing soon-to-be-released functionality. Content in this version is subject to change. Links to the v2.4 code base may not properly resolve until the code is officially released.

Extension Coding

The coding best practices presented in this section should be known and understood by you, the developer, when creating or maintaining your extensions. This ensures that the extension you develop behaves and functions correctly within the Magento application architecture. This guide is not only meant to educate you about coding best practices, but to also highlight some pitfalls we have seen other extension developers fall into so that you may avoid them.

For in depth content about creating extensions, see the PHP Developer Guide.