Title: Convert Blocks to JSON
Author: badasswp
Published: <strong>సెప్టెంబర్ 27, 2024</strong>
Last modified: ఫిబ్రవరి 27, 2026

---

Search plugins

![](https://ps.w.org/convert-blocks-to-json/assets/banner-772x250.png?rev=3158861)

![](https://ps.w.org/convert-blocks-to-json/assets/icon-256x256.png?rev=3158861)

# Convert Blocks to JSON

 By [badasswp](https://profiles.wordpress.org/badasswp/)

[Download](https://downloads.wordpress.org/plugin/convert-blocks-to-json.1.3.0.zip)

 * [Details](https://te.wordpress.org/plugins/convert-blocks-to-json/#description)
 * [Reviews](https://te.wordpress.org/plugins/convert-blocks-to-json/#reviews)
 *  [Installation](https://te.wordpress.org/plugins/convert-blocks-to-json/#installation)
 * [Development](https://te.wordpress.org/plugins/convert-blocks-to-json/#developers)

 [Support](https://wordpress.org/support/plugin/convert-blocks-to-json/)

## Description

This plugin offers a powerful solution for **importing** and **exporting** WordPress**
blocks** in JSON format, making it easy to move posts across different WP websites.
It is also beneficial for WP engineers who are adopting a **Headless CMS** approach
and would like a way to be able to fetch data from the front-end using tools like**
React**, Vue & so on.

It’s **simple**, yet very **powerful**!

#### ✔️ Features

Our plugin comes with everything you need for your WP blocks.

✔️ **Import & Export WP blocks** across multiple WordPress websites.
 ✔️ **Convert
WP blocks to JSON** easily & quickly. ✔️ Useful for **Headless CMS websites** or
front-end projects working with React, Vue & so on. ✔️ Available in **mutiple langauges**
such as Arabic, Chinese, Hebrew, Hindi, Russian, German, Italian, Croatian, Spanish,
French, Japanese, Indonesia, Turkish, Polish, Dutch, Danish, Brazil & Portuguese
languages. ✔️ Multiple **custom hooks** to enable you customize plugin to your heart’s
delight. ✔️ **Backward compatible**, works with most WP versions.

#### ✨ Getting Started

Create a new Post or open an existing Post. Locate the **Convert Blocks to JSON**
icon at the **top right** corner of the Block Editor and click on it. From here 
you can do the following actions:

 1. **View JSON** – Generate JSON data of the post you are working on.
 2. **Import JSON** – Import JSON data from a JSON file to the post you are working
    on.
 3. **Export JSON** – Export JSON data of the post to a JSON file.

You can get a taste of how this works, by using the [demo](https://tastewp.com/create/NMS/8.0/6.7.0/convert-blocks-to-json/twentytwentythree?ni=true&origin=wp)
link.

#### ✨ Why can’t I upload JSON files?

You might need to configure the `ALLOW_UNFILTERED_UPLOADS` option in your `wp-config.
php` file like so:

    ```
    define( 'ALLOW_UNFILTERED_UPLOADS', true );
    ```

#### ⚡ Why Convert Blocks to JSON

 1. This plugin is useful for users who want to be able to **import** and **export**
    articles or posts between different WordPress sites easily.
 2. This plugin is beneficial for WP engineers who are adopting a **Headless CMS** 
    approach and would like a way to be able to fetch data from the front-end using
    tools like **React**, Vue & so on.

#### 🔌🎨 Plug and Play or Customize

The **Convert Blocks to JSON** plugin is built to work right out of the box. Simply
install, activate and start using in your Block Editor.

Want to add your personal touch? All of our documentation can be found [here](https://github.com/badasswp/convert-blocks-to-json).
You can override the plugin’s behaviour with custom logic of your own using [hooks](https://github.com/badasswp/convert-blocks-to-json?tab=readme-ov-file#hooks).

### Contribute

If you’d like to contribute to the development of this plugin, you can find it on
[GitHub](https://github.com/badasswp/convert-blocks-to-json).

To build, clone repo and run `yarn install && yarn build`

## Screenshots

 * [[
 * Convert Blocks to JSON icon – Convert your blocks to JSON and vice versa.
 * [[
 * Convert Blocks to JSON options – View, Import Blocks & Export Blocks.
 * [[
 * Convert Blocks to JSON sidebar – See Convert Blocks to JSON on sidebar.

## Installation

 1. Go to ‘Plugins > Add New’ on your WordPress admin dashboard.
 2. Search for ‘Convert Blocks to JSON’ plugin from the official WordPress plugin repository.
 3. Click ‘Install Now’ and then ‘Activate’.
 4. Proceed to your Block Editor and locate the top right corner.
 5. You should now see the ‘Convert Blocks to JSON’ icon available for use.

## Reviews

There are no reviews for this plugin.

## Contributors & Developers

“Convert Blocks to JSON” is open source software. The following people have contributed
to this plugin.

Contributors

 *   [ badasswp ](https://profiles.wordpress.org/badasswp/)
 *   [ activist507 ](https://profiles.wordpress.org/activist507/)

“Convert Blocks to JSON” has been translated into 5 locales. Thank you to [the translators](https://translate.wordpress.org/projects/wp-plugins/convert-blocks-to-json/contributors)
for their contributions.

[Translate “Convert Blocks to JSON” into your language.](https://translate.wordpress.org/projects/wp-plugins/convert-blocks-to-json)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/convert-blocks-to-json/),
check out the [SVN repository](https://plugins.svn.wordpress.org/convert-blocks-to-json/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/convert-blocks-to-json/)
by [RSS](https://plugins.trac.wordpress.org/log/convert-blocks-to-json/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 1.3.0

 * Feat: Add language translations for Japanese, Indonesia, Turkish, Polish, Dutch,
   Danish, Brazil, Portuguese.
 * Feat: Add Image import functionality across websites.
 * Feat: Add custom hooks – `cbtj.afterImport`, `cbtj.innerBlocks`.
 * Feat: Add Notification modal during import.
 * Feat: Clear previous notifications before starting import.
 * Fix: Import issues with `core/list` and `core/list-item` blocks.
 * Fix: Import issues with `core/pargraph` block.
 * Fix: Import issues with `core/heading` block.
 * Fix: Import issues with `core/details` block.
 * Fix: Import issues with `core/pullquote` block.
 * Fix: Import issues with `core/cover` block.
 * Fix: Import issues with `core/table` block.
 * Fix: Import issues with `core/quote` block.
 * Fix: Import issues with `core/media-text` block.
 * Fix: Import issues with `core/gallery` block.
 * Fix: Import issues with `core/audio` block.
 * Fix: Import issues with `core/video` block.
 * Fix: Import issues with `core/footnotes` block.
 * Fix: Incorrectly quoted translation bits.
 * Refactor: Replace `get_400_response` with `get_error_response`.
 * Test: Add e2e tests for plugin codebase.
 * Chore: Add pull request template to repo.
 * Docs: Update README docs.
 * Tested up to WP 6.9.

#### 1.2.1

 * Specify `wordpress-plugin` as Composer package type.
 * Tested up to WP 6.9.

#### 1.2.0

 * Fix: Resolve `Image` block import issues.
 * Fix: Missing post title during import.
 * Feat: Add custom hooks `cbtj_import_block`, `cbtj_export_block`, `cbtj_blocks`.
 * Test: Add PHP unit tests to improve code.
 * Docs: Update README docs.
 * Tested up to WP 6.8.

#### 1.1.0

 * Feat: Add REST namespace filter `cbtj_rest_namespace`.
 * Refactor: Use classes for PHP codebase.
 * Docs: Improve README docs.
 * Tested up to WP 6.7.2.

#### 1.0.9

 * Bump up plugin version.
 * Tested up to WP 6.8
 * Update README docs.

#### 1.0.8

 * Enforce WP style linting across plugin.
 * Add local dev env setup for WP.
 * Update README docs.
 * Tested up to WP 6.7.2.

#### 1.0.7

 * Ensure `REST` response for blocks’ imports & exports.
 * Update Hook names `cbtj_rest_response` to `cbtj_rest_export`.
 * Update function names.
 * Update README docs.
 * Tested up to WP 6.7.2.

#### 1.0.6

 * Fix breaking/faulty dependency.
 * Fix linting issues.
 * Tested up to WP 6.7.1.

#### 1.0.5

 * Fix CI/CD build process.
 * Update README text content.
 * Bump up plugin version.
 * Tested up to WP 6.7.0.

#### 1.0.4

 * Provide graceful fallback for block arrays.
 * Filter out empty|null blocks.
 * Ignore `file_get_contents` warning.
 * Update Permalink structure if empty, flush rules.
 * Tested up to WP 6.6.2.

#### 1.0.3

 * Replace `mt_rand` with `string` version for asset enqueuing.
 * Fix Bugs and Linting issues.
 * Updated README notes with screenshots.
 * Tested up to WP 6.6.2.

#### 1.0.2

 * Refactor: Use `is_user_permissible` for permissions callback.
 * Updated Unit Tests coverage.
 * Tested up to WP 6.6.2.

#### 1.0.1

 * Added Import functionality.
 * Custom Hooks – `cbtj_rest_import`.
 * New custom REST API endpoint – `cbtj/v1/import`.
 * Updated translation files to cater for Import modal window text translations.
 * Added more Unit Tests coverage.
 * Tested up to WP 6.6.2.

#### 1.0.0

 * Convert & Export Blocks to JSON.
 * Custom Hooks – `cbtj_rest_response`.
 * Provided support for Arabic, Chinese, Hebrew, Hindi, Russian, German, Italian,
   Croatian, Spanish & French languages.
 * Unit Tests coverage.
 * Tested up to WP 6.6.1.

## Meta

 *  Version **1.3.0**
 *  Last updated **2 నెలలు ago**
 *  Active installations **40+**
 *  WordPress version ** 4.0 or higher **
 *  Tested up to **6.9.4**
 *  PHP version ** 7.4 or higher **
 *  Languages
 * [Croatian](https://hr.wordpress.org/plugins/convert-blocks-to-json/), [English (US)](https://wordpress.org/plugins/convert-blocks-to-json/),
   [Italian](https://it.wordpress.org/plugins/convert-blocks-to-json/), [Russian](https://ru.wordpress.org/plugins/convert-blocks-to-json/),
   [Spanish (Chile)](https://cl.wordpress.org/plugins/convert-blocks-to-json/), 
   [Spanish (Spain)](https://es.wordpress.org/plugins/convert-blocks-to-json/).
 *  [Translate into your language](https://translate.wordpress.org/projects/wp-plugins/convert-blocks-to-json)
 * Tags
 * [blocks](https://te.wordpress.org/plugins/tags/blocks/)[convert](https://te.wordpress.org/plugins/tags/convert/)
   [editor](https://te.wordpress.org/plugins/tags/editor/)[gutenberg](https://te.wordpress.org/plugins/tags/gutenberg/)
   [JSON](https://te.wordpress.org/plugins/tags/json/)
 *  [Advanced View](https://te.wordpress.org/plugins/convert-blocks-to-json/advanced/)

## Ratings

No reviews have been submitted yet.

[Your review](https://wordpress.org/support/plugin/convert-blocks-to-json/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/convert-blocks-to-json/reviews/)

## Contributors

 *   [ badasswp ](https://profiles.wordpress.org/badasswp/)
 *   [ activist507 ](https://profiles.wordpress.org/activist507/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/convert-blocks-to-json/)