How to Write a Claude Prompt That Gets Expert Results
Claude and ChatGPT are built on fundamentally different design philosophies, and prompts that work well in one often underperform in the other. Claude tends to be more literal, more thorough with long documents, more willing to push back on ambiguous or potentially harmful requests, and significantly better at following structured formatting instructions. Understanding these differences lets you write prompts that unlock Claude's actual strengths rather than treating it like a generic AI assistant.
How Claude is different from ChatGPT
Claude was trained with Constitutional AI — a process where the model was trained to evaluate its own outputs against a set of principles. In practice, this means Claude will more readily identify edge cases in your request, ask clarifying questions when instructions are ambiguous, and push back on requests that seem to conflict. This is actually useful behavior if you work with it rather than against it: Claude will tell you when your prompt has a hole in it that you might not have noticed.
Claude handles very long context windows (up to 200K tokens on Claude 3 models) with remarkable fidelity. You can paste an entire legal contract, a long research paper, or a full codebase into the context and Claude will reason across all of it. It doesn't "forget" the beginning of a long document the way some models do. This makes Claude particularly strong for document analysis, long-form writing, and multi-document synthesis tasks.
Claude follows instructions more literally than ChatGPT. If you say "respond in under 200 words," Claude will stay under 200 words. If you specify a structure, it will follow that structure precisely. This is a feature when your prompts are well-specified. It's a limitation when your prompts are vague — Claude won't creatively fill gaps the way ChatGPT sometimes does.
Claude-specific techniques that make a real difference
Use XML tags for structure
Claude is trained to parse XML-style tags as structural separators. Wrapping sections of your prompt in tags like <task>, <context>, <format>, and <constraints> gives Claude a clear map of what each section is for. This is one of the single biggest improvements you can make to long prompts — Claude's instruction-following accuracy improves noticeably when sections are explicitly labeled.
Set the role explicitly
Claude responds very well to explicit role-setting at the top of a prompt. Opening with "You are a [specific role] with [specific experience]" establishes the frame before the task, which means Claude's entire response is generated from that perspective. The role should be specific enough to matter — not "you are an expert" but "you are a CFO who has managed treasury operations at mid-size manufacturing companies."
Ask for step-by-step reasoning on complex tasks
For tasks involving analysis, evaluation, or multi-step decisions, explicitly tell Claude to reason through the problem before giving its answer. Add a line like "Think through this step by step before giving your final recommendation" or use a <thinking> tag to request a visible scratchpad. Claude's extended thinking mode produces noticeably better outputs on complex analytical tasks when reasoning is made explicit.
Give Claude explicit permission to be direct
Claude's training makes it naturally cautious and hedge-heavy on sensitive topics. If you want a direct, opinionated answer, tell it explicitly: "Be direct and give me your honest assessment, not a balanced overview" or "I don't need caveats — give me your recommendation." Without this permission, Claude will often produce thorough but frustratingly non-committal responses on judgment calls.
5 Example Claude Prompts Using XML Structure
Legal document analysis
You are a commercial contracts attorney with 15 years of experience reviewing SaaS vendor agreements. <context> I am a Head of Engineering at a 200-person startup evaluating a data processing agreement from a cloud infrastructure vendor. The contract is 18 pages. I need to understand the risk profile before signing. My primary concerns: data ownership, liability caps, indemnification scope, and termination rights. </context> <task> Review the contract below and produce a risk assessment. Identify the 5 most significant clauses I should either negotiate or have legal counsel review before signing. For each clause: quote the exact language, explain why it's risky in plain English, and suggest specific alternative language I could request. </task> <format> Numbered list of 5 clauses. Each entry: - Clause name and location (section number) - Quoted language (exact) - Risk explanation (2–3 sentences, no jargon) - Suggested negotiation position End with a single overall risk rating: Low / Medium / High / Do Not Sign Without Legal Review. </format> <constraints> Do not summarize the entire contract — focus only on the highest-risk items. If you identify a clause that should be an automatic dealbreaker, flag it separately at the top before the numbered list. </constraints> [CONTRACT TEXT PASTED BELOW]
Research synthesis across multiple sources
You are a senior market research analyst who specializes in synthesizing conflicting information into clear, defensible conclusions. <context> I am a VP of Product deciding whether to add AI-generated content features to our B2B writing tool. I've gathered research from 3 sources that have somewhat conflicting findings: - Source A (enterprise software analyst report, 2024): 67% of B2B buyers say AI-generated content reduces trust in vendor communications - Source B (our own user survey, n=340, 2024): 48% of our users already use AI to draft content in our tool via copy-paste from ChatGPT - Source C (competitor's case study): a direct competitor launched an AI writing feature and saw 23% increase in premium plan upgrades within 6 months These findings seem to conflict. I need to make a recommendation to the leadership team within 2 weeks. </context> <task> Synthesize these three sources into a coherent analysis. Identify where the conflicts are real vs. where they're measuring different things. Then give me your honest assessment of what the data actually supports. </task> <format> 1. Brief synthesis: explain the apparent conflict and whether it's real (2–3 paragraphs) 2. What the data actually supports (3 bullet points) 3. What's missing from this dataset that would change the conclusion 4. Your recommendation: build, delay, or don't build — with the primary reason </format> <constraints> Be direct. I don't need a "here are all the considerations" answer — I need a recommendation I can defend to leadership. If the data is genuinely insufficient to recommend either way, say so explicitly and tell me what data I need to collect first. </constraints>
Code review with specific quality criteria
You are a senior backend engineer specializing in Python and distributed systems, with a particular focus on production readiness and observability. <context> I am preparing a code review for a payment processing module written by a mid-level engineer. The code handles webhook events from Stripe, updates our database, and triggers downstream notifications. This code will go into production handling ~$200K/day in transactions. The engineer is good but relatively new to production-grade payment systems. </context> <task> Review the code pasted below. Identify issues across 4 categories: 1. Correctness and edge cases (what could fail silently or produce wrong data) 2. Security and compliance (payment data handling, logging of sensitive fields) 3. Resilience (retry logic, idempotency, failure modes under load) 4. Observability (are there enough logs/metrics to debug a production incident at 2am) </task> <format> For each issue found: - Category (from the 4 above) - Severity: Critical / High / Medium / Low - Description of the issue (2–3 sentences) - Specific code change recommendation (include code snippets where helpful) End with: a summary of how many issues by severity, and whether this code is ready to merge, needs minor changes, or needs significant rework before it's production-safe. </format> <constraints> Do not just list best practices — only flag issues that are actually present in this specific code. If the code handles something correctly, say so. The engineer will read this review, so be direct but constructive. </constraints> [CODE PASTED BELOW]
Strategic decision memo with explicit tradeoffs
You are a management consultant who has advised Series B–D technology companies on build vs. buy decisions for core infrastructure. <context> I am the CTO of a 120-person fintech company. We currently use a third-party identity verification vendor (IDV) that costs us $1.2M/year and has 97.3% verification accuracy. Our engineering team has proposed building our own IDV system, estimating 8–12 months and a 6-person team. Our investors are pushing for faster unit economics improvement. This decision has major implications for our compliance posture (we're regulated under FinCEN). </context> <task> Evaluate the build vs. buy decision and produce a decision memo. Do not give me a generic framework — apply it to our specific situation with real estimates where you can and explicit assumptions where you can't. </task> <format> 1. Decision framing: what are we actually deciding and what are the real constraints 2. Build case: strongest 3 arguments, with quantified estimates where possible 3. Buy/continue case: strongest 3 arguments 4. Risks that most decision memos ignore (the failure modes that sink these projects) 5. Recommendation with primary rationale 6. What I should validate before committing (2–3 specific things to check) </format> <constraints> Be direct. If one path is clearly better given what I've told you, say so. I don't need a perfectly balanced "it depends" answer — I need a position I can test against my board. If you don't have enough information to recommend, tell me exactly what you need. </constraints>
Long document editing with style guide enforcement
You are a senior editor with expertise in technical and business writing. You work with engineering leaders, product managers, and startup founders to make their writing clearer and more direct.
<context>
I have written a 1,200-word blog post about our approach to database schema migrations at scale. The target audience is senior engineers and engineering managers at companies with 50–500 engineers. I want this post to establish credibility and drive newsletter sign-ups from that audience. The post currently feels too academic — it reads like a technical spec, not a practitioner's perspective.
</context>
<task>
Edit the post below for the following:
1. Voice: make it sound like a practitioner sharing hard-won lessons, not a textbook. First person, confident, willing to have opinions.
2. Structure: the current structure buries the most interesting insight in paragraph 6 — restructure so the most surprising or useful thing comes first.
3. Concision: cut at least 20% of the word count without losing substance.
4. Specificity: anywhere I've written vague generalizations ("this can be challenging"), replace with specific examples or cut it.
</task>
<format>
Return the edited post in full. After the post, add an "Editor's notes" section with:
- 3–5 specific changes you made and why
- Any places where you weren't sure of my intent and made an assumption
- 1–2 suggestions for the title/headline (current title is weak)
</format>
<constraints>
Do not change the technical accuracy of anything. If a technical claim is unclear to you, mark it with [VERIFY] rather than editing it. Preserve all code examples exactly as written.
</constraints>
[POST TEXT BELOW]Tips for Writing Claude Prompts
Claude's Constitutional AI training means it will sometimes push back on requests that seem clear to you but have an edge case Claude finds problematic. This isn't a bug to work around — it's often Claude identifying a genuine ambiguity. When Claude pushes back or hedges unexpectedly, read its reasoning: it usually tells you exactly what it's uncertain about, and clarifying that in your prompt will unlock the response you wanted.
Claude's long context capability is genuinely useful but requires good prompt hygiene. When you paste a long document and ask Claude to analyze it, be specific about what you're looking for — otherwise Claude will produce a comprehensive summary of everything rather than the targeted analysis you need. The larger the document, the more precise your task instruction needs to be. "Find the 3 highest-risk clauses" outperforms "review this contract."
If you're using Claude for tasks where your preferred style matters — writing, editing, tone — consider providing a reference example in your prompt. Claude is excellent at pattern-matching to a sample you provide. "Write in a similar style to this example: [paste example]" consistently outperforms describing the style in words alone, especially for voice and tone calibration.
Why use PromptBro to write Claude prompts?
PromptBro includes a model selection step where you can specifically choose Claude as your target platform — and the generated prompt is structured accordingly, with XML tags and explicit section labels that Claude responds to best. The 6-step flow ensures your prompt has role, context, task, format, and constraints fully specified before it's assembled, which is exactly the structure Claude performs best with. Speak your goal out loud and let PromptBro handle the prompt engineering.
Try PromptBro free — build your first Claude prompt in 60 seconds →