{"id":80229,"date":"2026-11-25T09:19:19","date_gmt":"2026-11-25T09:19:19","guid":{"rendered":"https:\/\/www.devopsschool.com\/blog\/?p=80229"},"modified":"2026-11-25T09:20:08","modified_gmt":"2026-11-25T09:20:08","slug":"how-to-import-docx-into-wordpress-with-mammoth-text-images-tables-and-code","status":"publish","type":"post","link":"https:\/\/www.devopsschool.com\/blog\/how-to-import-docx-into-wordpress-with-mammoth-text-images-tables-and-code\/","title":{"rendered":"How to Import DOCX into WordPress with Mammoth: Text, Images, Tables and Code"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">A practical, single-file publishing workflow for bloggers, technical writers and DevOps training teams.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1200\" height=\"630\" src=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/docx-plus-mammoth-workflow-from-embedded-assets-to.png\" alt=\"DOCX plus Mammoth workflow from embedded assets to WordPress publishing.\" class=\"wp-image-80230\" srcset=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/docx-plus-mammoth-workflow-from-embedded-assets-to.png 1200w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/docx-plus-mammoth-workflow-from-embedded-assets-to-300x158.png 300w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/docx-plus-mammoth-workflow-from-embedded-assets-to-1024x538.png 1024w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/docx-plus-mammoth-workflow-from-embedded-assets-to-768x403.png 768w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/docx-plus-mammoth-workflow-from-embedded-assets-to-820x430.png 820w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"caption wp-block-paragraph\">\n  Figure 1. Original featured illustration (1200 \u00d7 630 pixels).<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">  Writing an excellent tutorial is only half the job. Moving it into WordPress without losing screenshots, diagrams, tables or executable commands is often the frustrating part. A self-contained Word document and the Mammoth converter provide a practical alternative to manually uploading each image or copying rendered HTML.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This guide explains how to prepare a document, import it, preserve technical code and verify the result. The workflow was demonstrated on a public DevOpsSchool test post on November 25, 2026. The larger tutorial you are reading is also designed as an import acceptance test.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What you need<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><br>    A WordPress site where you can install or request plugins.<\/li>\n\n\n\n<li><br>    A user account permitted to edit posts and upload media.<\/li>\n\n\n\n<li><br>    A trusted .docx file with embedded PNG or JPEG images and semantic paragraph styles.<\/li>\n\n\n\n<li><br>    A staging site or unpublished draft for the first import.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">1. Understand the DOCX + Mammoth workflow<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Mammoth converts the structure of a Word document into clean HTML. It interprets headings, lists, tables, images and links rather than reproducing every Word font, margin or color. WordPress and your theme determine the final web presentation.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1200\" height=\"410\" src=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/four-stages-docx-with-images-semantic-html-conve.png\" alt=\"Four stages: DOCX with images, semantic HTML conversion, media uploads, draft review.\" class=\"wp-image-80231\" srcset=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/four-stages-docx-with-images-semantic-html-conve.png 1200w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/four-stages-docx-with-images-semantic-html-conve-300x103.png 300w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/four-stages-docx-with-images-semantic-html-conve-1024x350.png 1024w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/four-stages-docx-with-images-semantic-html-conve-768x262.png 768w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"caption wp-block-paragraph\">\n  Figure 2. Single-document publishing architecture.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Why use DOCX rather than copy and paste?<\/h3>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th><strong>Method<\/strong><\/th><th><strong>Images<\/strong><\/th><th><strong>Code and layout<\/strong><\/th><\/tr><\/thead><tbody><tr><td>\n  HTML \/ Markdown paste<\/td><td>\n  Local references can be lost<\/td><td>\n  Code may survive; image paths often need work.<\/td><\/tr><tr><td>\n  Google Docs paste<\/td><td>\n  Depends on clipboard and editor<\/td><td>\n  Whitespace and punctuation need checking.<\/td><\/tr><tr><td>\n  DOCX + Mammoth<\/td><td>\n  Importer can upload embedded images<\/td><td>\n  Semantic structure; custom code map recommended.<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">2. Install and activate Mammoth<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In WordPress Admin, open Plugins \u2192 Add New Plugin. Search for Mammoth .docx converter by Michael Williamson, then install and activate it. Alternatively, run the following from your WordPress installation directory with WP-CLI and appropriate permissions:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-1\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php\">wp plugin install mammoth-docx-converter --activate\nwp plugin <span class=\"hljs-keyword\">list<\/span> --name=mammoth-docx-converter<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-1\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p class=\"wp-block-paragraph\">For existing production sites, review plugin compatibility and your normal change approval process before installing. If the plugin is already active, skip installation.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">3. Prepare a self-contained Word document<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Ask your author or AI assistant to generate a real DOCX, not a renamed Markdown or HTML file. Use inline images stored inside the document. Add meaningful alternative text and normal caption paragraphs. Use Heading 1 for the article title, Heading 2 for sections and Heading 3 or 4 for subsections.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Create a code-friendly paragraph style<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Use a custom paragraph style named Code Block for commands and configuration. Keep each source-code line in its own paragraph with literal leading spaces; avoid smart quotes, smart dashes and automatic lists. The style alone is not enough: embed a Mammoth style map in the DOCX.<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-2\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php\">p&#91;style-name=<span class=\"hljs-string\">'Code Block'<\/span>] =&gt; pre &gt; code:separator(<span class=\"hljs-string\">'\\n'<\/span>)\np&#91;style-name=<span class=\"hljs-string\">'Caption'<\/span>] =&gt; p.caption:fresh<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-2\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p class=\"wp-block-paragraph\">This mapping groups consecutive code paragraphs into a preformatted code element and separates them with newline characters. It is already embedded in this document. Authors preparing their own documents can use the official Mammoth style-map embedding tool or the library API.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/mike.zwobble.org\/projects\/mammoth\/embed-style-map\/\" rel=\"noopener\">Mammoth embedded style-map tool<\/a><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Example: a multiline shell command<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The following command is a formatting test as well as a real Helm example. It is intended for an authorized development cluster with Helm installed; you do not need to execute it to test publishing.<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-3\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php\">helm repo add headlamp https:<span class=\"hljs-comment\">\/\/kubernetes-sigs.github.io\/headlamp\/<\/span>\nhelm repo update\nhelm upgrade --install headlamp headlamp\/headlamp \\\n  --<span class=\"hljs-keyword\">namespace<\/span> <span class=\"hljs-title\">headlamp<\/span> \\\n  --<span class=\"hljs-title\">create<\/span>-<span class=\"hljs-title\">namespace<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-3\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<h3 class=\"wp-block-heading\">Example: indentation-sensitive YAML<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Save the example as values.yaml if you want to test a YAML parser. It is illustrative Helm configuration, not an instruction to change your cluster.<\/p>\n\n\n<pre class=\"wp-block-code\"><span><code class=\"hljs\">replicaCount: 1\nservice:\n  type: ClusterIP\n  port: 80\nresources:\n  requests:\n    cpu: 100m\n    memory: 128Mi<\/code><\/span><\/pre>\n\n\n<p class=\"wp-block-paragraph\">The two and four leading spaces must remain unchanged after import. Do not replace code with a screenshot: readers must be able to select and copy it.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">4. Import the document into WordPress<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Open Posts \u2192 Add New. In the block editor, scroll below the main content area. In Classic Editor, look beneath the writing area. The converter is a post-editor panel, not necessarily a separate item in the admin sidebar.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1200\" height=\"520\" src=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/illustrative-wordpress-editor-with-mammoth-choose.png\" alt=\"Illustrative WordPress editor with Mammoth Choose File and Insert into editor controls.\" class=\"wp-image-80232\" srcset=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/illustrative-wordpress-editor-with-mammoth-choose.png 1200w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/illustrative-wordpress-editor-with-mammoth-choose-300x130.png 300w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/illustrative-wordpress-editor-with-mammoth-choose-1024x444.png 1024w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/illustrative-wordpress-editor-with-mammoth-choose-768x333.png 768w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"caption wp-block-paragraph\">\n  Figure 3. Schematic of the importer panel; not an actual WordPress screenshot.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">If the Mammoth panel is hidden<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Confirm that the plugin is active. In Classic Editor, open Screen Options and enable the Mammoth panel if listed. In Gutenberg, inspect Preferences and available panels, then scroll below the editor. Panel names and locations vary by version. If necessary, test with the official Classic Editor plugin on a staging site.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Select the DOCX and insert it<\/h3>\n\n\n\n<ol class=\"wp-block-list\">\n<li><br>  Click Choose File in the Mammoth panel and select the .docx document.<\/li>\n\n\n\n<li><br>  Review the converted preview. Check that all images and code examples appear.<\/li>\n\n\n\n<li><br>  Click Insert into editor. Do not copy the preview using the clipboard.<\/li>\n\n\n\n<li><br>  Allow the import to complete. Save the post as a draft.<\/li>\n\n\n\n<li><br>  Open Media \u2192 Library and confirm that the embedded images were uploaded.<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">If the post title is blank, enter it manually. If the document heading duplicates the theme-generated post title, remove the duplicate heading from the body. Select the first image as the featured image if desired; Mammoth does not automatically configure SEO or featured images.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">5. Final hands-on verification: test this tutorial<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Import this very document into a new draft. It includes four actual PNG illustrations, multiple code examples, semantic headings, lists, a table and hyperlinks. This makes it a useful end-to-end test of your publishing process.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1200\" height=\"390\" src=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/verification-categories-for-four-images-exact-cod.png\" alt=\"Verification categories for four images, exact code syntax and content structure.\" class=\"wp-image-80233\" srcset=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/verification-categories-for-four-images-exact-cod.png 1200w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/verification-categories-for-four-images-exact-cod-300x98.png 300w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/verification-categories-for-four-images-exact-cod-1024x333.png 1024w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2026\/11\/verification-categories-for-four-images-exact-cod-768x250.png 768w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"caption wp-block-paragraph\">\n  Figure 4. Pre-publication quality checks.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th><strong>Check<\/strong><\/th><th><strong>Pass condition<\/strong><\/th><\/tr><\/thead><tbody><tr><td>\n  Images and ALT text<\/td><td>\n  All four figures are visible; image URLs point to approved permanent media storage.<\/td><\/tr><tr><td>\n  Code blocks<\/td><td>\n  Multiline commands use real code formatting; &#8212; flags and backslashes remain intact.<\/td><\/tr><tr><td>\n  YAML<\/td><td>\n  Two- and four-space indentation is preserved.<\/td><\/tr><tr><td>\n  Tables and lists<\/td><td>\n  Rows and columns are readable; lists retain structure.<\/td><\/tr><tr><td>\n  Links and headings<\/td><td>\n  Links open correctly; the article has one main title and logical sections.<\/td><\/tr><tr><td>\n  Responsive preview<\/td><td>\n  Images, tables and code remain usable on desktop and mobile.<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Special-character test (safe to execute locally)<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Copy the following Bash snippet from the published post. It only prints text. Compare its output with the expected line below; it verifies quotation marks, dollar signs and shell metacharacters.<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-4\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript\">printf <span class=\"hljs-string\">'%s\\n'<\/span> <span class=\"hljs-string\">'--flag \"quoted\" $HOME &lt;tag&gt; A&amp;B'<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-4\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p class=\"wp-block-paragraph\">Expected output:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-5\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php\">--flag <span class=\"hljs-string\">\"quoted\"<\/span> $HOME &lt;tag&gt; A&amp;B<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-5\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p class=\"wp-block-paragraph\">If a command changes after copying, inspect the underlying HTML. Do not publish until the source text is correct.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">6. Troubleshoot import and formatting issues<\/h2>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th><strong>Symptom<\/strong><\/th><th><strong>What to do<\/strong><\/th><\/tr><\/thead><tbody><tr><td>\n  No converter panel<\/td><td>\n  Check plugin activation and editor panel visibility; test Classic Editor if needed.<\/td><\/tr><tr><td>\n  Images visible in preview but absent in post<\/td><td>\n  Use Insert into editor; confirm upload permissions, media errors, file size limits and Media Library entries.<\/td><\/tr><tr><td>\n  Double hyphens or quotes change<\/td><td>\n  Verify the embedded style map and that code is inside pre\/code elements.<\/td><\/tr><tr><td>\n  YAML loses indentation<\/td><td>\n  Check literal spaces and preformatted markup; avoid normal paragraphs for source code.<\/td><\/tr><tr><td>\n  Table borders or fonts differ<\/td><td>\n  Theme styling controls appearance; use simple tables and semantic headings.<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Optional verification using WP-CLI<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Run these read-only checks from the WordPress directory. Replace 123 with the draft post ID. The attachment listing is site-wide, so match images to the imported article.<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-6\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript\">wp post <span class=\"hljs-keyword\">get<\/span> 123 --field=post_content\nwp post list --post_type=attachment --posts_per_page=10 \\\n  --fields=ID,post_title,post_mime_type<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-6\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p class=\"wp-block-paragraph\">Look for image elements with permanent URLs and pre\/code elements enclosing commands. WordPress wptexturize normally skips these elements, which helps prevent typographic punctuation changes.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Evidence from a live test<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">On November 25, 2026, a small Headlamp DOCX imported via Mammoth was publicly accessible with its embedded image, caption, table and multiline Helm commands intact. That verifies the earlier sample, not yet this larger document. The current document must be imported and reviewed on your own site before calling the new test complete.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/www.devopsschool.com\/blog\/80226-2\/\">DevOpsSchool: successful Headlamp WordPress import test<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">7. A reusable prompt for future AI-generated blogs<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Generate a complete, publication-ready technical article as one DOCX file for Mammoth. Embed every original diagram and image with ALT text and captions. Use semantic headings, real tables, lists and hyperlinks. Use Code Block paragraphs and an embedded Mammoth style map to preserve exact source code, whitespace and punctuation. Validate the file before delivery. Do not provide separate image files or ZIP archives.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">8. Frequently asked questions<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">Does Mammoth preserve everything exactly as Word displays it?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">No. It aims to preserve semantic content rather than reproduce the original page layout. Your WordPress theme may change fonts, spacing and borders. Always preview the web version.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Do I need to upload images separately?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Normally not when the images are embedded and the import succeeds. The converter uploads images as part of insertion. Verify the resulting files in the Media Library.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Can Mammoth preserve Bash, Python, JSON and YAML?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Yes, with properly prepared code paragraphs and a compatible style map. Syntax highlighting is optional and depends on WordPress styling or a dedicated plugin. Always compare copied code to the source.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Can I use Gutenberg and Classic Editor?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Mammoth has basic block-editor support as well as Classic Editor support. Exact compatibility depends on your WordPress version, theme and plugins. Test the editor your content team actually uses.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Will it automatically set categories, SEO and the featured image?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Do not assume so. Enter the title, slug, categories and SEO fields in your chosen SEO plugin, and select the featured image in WordPress. These are separate from importing the article body.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The most convenient workflow for rich technical tutorials is a single trusted DOCX, imported into WordPress through Mammoth and checked as a draft. Embedded images eliminate separate media handling in successful imports, while semantic styles and a code mapping help protect executable examples. One document, one import, one quality review.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Official references<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/wordpress.org\/plugins\/mammoth-docx-converter\/\" rel=\"noopener\">Mammoth WordPress plugin<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/github.com\/mwilliamson\/mammoth-wordpress-plugin\" rel=\"noopener\">Mammoth plugin source code<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/github.com\/mwilliamson\/mammoth.js\" rel=\"noopener\">Mammoth.js style maps<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/developer.wordpress.org\/reference\/functions\/wptexturize\/\" rel=\"noopener\">WordPress wptexturize documentation<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/developer.wordpress.org\/cli\/commands\/post\/get\/\" rel=\"noopener\">WP-CLI post get<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>A practical, single-file publishing workflow for bloggers, technical writers and DevOps training teams. Figure 1. Original featured illustration (1200 \u00d7 630 pixels). Writing an excellent tutorial is&#8230; <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_joinchat":[],"footnotes":""},"categories":[49],"tags":[],"class_list":["post-80229","post","type-post","status-publish","format-standard","hentry","category-general"],"_links":{"self":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/80229","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/comments?post=80229"}],"version-history":[{"count":2,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/80229\/revisions"}],"predecessor-version":[{"id":80235,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/80229\/revisions\/80235"}],"wp:attachment":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/media?parent=80229"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/categories?post=80229"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/tags?post=80229"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}