Convert raw HTML to Gutenberg blocks automatically.
This plugin converts raw HTML content into Gutenberg block arrays, using WordPress Core's HTML API for spec-compliant parsing. It is designed for developers migrating legacy content, importing from external sources via REST API, or programmatically creating posts with block-based structure. It works in two modes: as a standalone plugin that automatically converts HTML on post save and REST editor reads, or as a Composer package for direct integration.
wp_insert_post_data and REST API edit context to convert raw HTML to blocks without manual intervention. No "Convert to blocks" prompt needed.html_to_blocks_raw_handler() with an HTML string to get a block array, then serialize with serialize_blocks(). Useful for adapter pipelines or custom import scripts.composer require chubes4/html-to-blocks-converter and load inside WordPress. The version registry ensures only the newest loaded copy initializes, avoiding conflicts when multiple plugins bundle the package.core/html with a fallback action for logging.html_to_blocks_supported_post_types to enable conversion on custom post types. Defaults to all public REST-enabled post types.No comments yet. Be the first to start the conversation!