claude formatting not working
Learn how to fix issues when Claude fails to format markdown, code blocks, tables, or JSON output correctly in the web app or via the API.
Updated 8/18/2026Powered by Tickd.ai
If Claude is outputting raw text, unformatted code, or broken tables instead of clean markdown, you are dealing with a formatting failure. This can happen in both the consumer web interface and when calling models via the Anthropic API. Usually, formatting errors occur due to browser rendering issues, overloaded servers, or ambiguous instructions in the system prompt.
Force markdown rendering in your prompt
When Claude outputs plain text instead of structured tables or highlighted code, the issue usually stems from vague instructions. To resolve this, explicitly instruct the model to use standard Markdown syntax. For example, instead of asking for a table, write: "Provide the data in a clean Markdown table format with proper headers." If you need code, specify the programming language explicitly to ensure the syntax highlighting renders correctly in the chat interface.
Fix JSON output formatting in the API
If you are using the Anthropic API and Claude is failing to return valid JSON, you need to adjust your prompting strategy. Unlike some other engines, Claude does not have a native, strict "JSON mode" toggle, but it is highly proficient at outputting structured data when instructed via XML tags. Provide a schema inside <schema> tags in your system prompt and instruct Claude to "output only valid JSON, starting with { and ending with }" without any conversational preambles.
Clear browser cache or reload the page
Sometimes, the issue is not with Claude's actual output but with the web browser's ability to render the frontend styling. If formatting elements like bold text, bullet points, or code block containers appear as raw text, the rendering engine might have frozen. Perform a hard refresh (Ctrl + F5 on Windows or Cmd + Shift + R on Mac). If the web interface remains unresponsive or fails to display any styled elements at all, you may need to troubleshoot issues with the app interface itself by visiting our guide on Claude app wont load.
Use XML tags to structure your prompt
Anthropic models are trained specifically on XML tags (such as <instructions>, <formatting>, and <output>). If Claude is ignoring your formatting rules, wrap your formatting guidelines in custom tags. For instance: <formatting_rules> Use bullet points for lists and bold the first three words of each bullet. </formatting_rules> This clear separation of content and instructions prevents the model from conflating formatting rules with the text it is meant to process.
Manage server load and API timeouts
During periods of high server load, Claude might abort generation early or fail to apply system instructions properly, resulting in truncated or raw outputs. If you suspect server issues are causing unformatted responses, check the Anthropic API 529 overloaded error guide. If the model refuses to output anything after a formatting error occurs, refer to our troubleshooting steps for Claude not responding.