API versions ensure backward compatibility as WordPress block development evolves. When WordPress introduces breaking changes, blocks specify their compatible API version in block.json to maintain functionality.
API version 3 introduces useBlockProps hook requirements for both edit and save functions. This hook provides essential WordPress classes and attributes that make blocks selectable and properly integrated with the editor.
The useBlockProps() hook in edit functions provides editor-specific props, while useBlockProps.save() generates appropriate markup for frontend display. This separation ensures blocks work correctly in both contexts while maintaining WordPress standards.