B1.3Bloom · ENot started

Artifact vs inline message

Reading depth

What you'll learn

Artifacts park long deliverables in a side pane so they don't replay in the chat history every turn. Use them when the output is something the user will iterate on or carry away.

  • Artifact = isolated, iterable, re-renderable output. Inline = part of the conversation.
  • Inlining long output bloats the chat history that replays every turn.
  • Artifacts are for deliverables; inline is for conversation.

An Artifact is a separate, isolated, re-renderable output surface inside Claude.ai — code blocks, long documents, diagrams, HTML previews. The point of the Artifact construct isn't visual polish; it's to keep long deliverables *out* of the conversational message stream so the chat thread doesn't bloat with multi-thousand-token blobs every turn.

When Claude inlines a 4,000-word doc into a chat reply, every subsequent turn carries that doc in the conversation history. By turn five the system is replaying ~20K tokens of duplicated draft content just to maintain the thread. When the same doc is an Artifact, the chat thread holds a small reference / preview while the heavy content lives in its own pane that can be edited, re-rendered, and replaced in place.

The decision is structural, not aesthetic. Use an Artifact when the output is (a) long enough that replaying it on every turn is wasteful, (b) something the user will iterate on (edit, ask for v2, copy out), or (c) a self-contained deliverable (a doc, a script, a diagram) rather than a piece of the conversation. Use inline when the answer *is* the conversation — short replies, explanations, decisions.

Two anti-patterns: inlining a 5K-word draft because 'it's just one message' (the cost is the *next* five turns, not this one), and Artifact-everything (short replies wrapped in Artifacts feel formal but break the conversational flow and add UI friction).

Key points

  • Artifact = isolated, iterable, re-renderable output. Inline = part of the conversation.
  • Inlining long output bloats the chat history that replays every turn.
  • Artifacts are for deliverables; inline is for conversation.
  • Token cost per Artifact is identical to inline — the win is structural, not economic per call.

Examples

Drafting a 4,000-word policy doc

Inline: ~5K tokens added to chat history, replayed every subsequent turn — by turn 6 you're paying 30K tokens of duplicated draft just to keep talking. Artifact: the doc lives in its own pane; the chat history references it; iteration replaces the Artifact in place. Same first-turn cost; massively different recurring cost.

Quick clarifying question

User asks 'what does this error mean?' A two-sentence answer is conversation, not deliverable. Inline. Wrapping it in an Artifact adds UI ceremony and makes the next turn awkward.

Pitfalls

  • 'Make it nicer, put it in an Artifact' — if it's three sentences, no.
  • Inlining long output and then asking for 'v2 with one change' — the v2 is also inline, doubling the bloat.
  • Treating Artifacts as a magic cost-saver. Per-call token cost is the same; the saving is on subsequent turns of the *same* conversation.

Source notes: 00-academy-basics/notes/01-claude-101.md

Ask Claude

Build a prompt with this lesson + your question, copy it, and open the Claude Project in a new tab.