How to Use XML Tags in Claude Prompts
Wrapping parts of your prompt in simple tags is one of the easiest ways to get more reliable answers from Claude. A practical guide with examples.
Paste a file tree and a few key files. Claude gives you the tour a senior engineer would: how a request flows, where things live and what to avoid.
Act as the engineer who has maintained this codebase for three years. I joined the team today. File tree: ``` [PASTE THE OUTPUT OF: tree -L 3 -I node_modules] ``` The most important files: [PASTE 2 TO 5 FILES: the entry point, a core model, one typical route or handler] Give me the tour: 1. One paragraph on what this system does and how it is put together. 2. Follow one typical request from the entry point to the database and back. Name the real files and functions it passes through. 3. The five concepts I have to understand, and how they relate to each other. 4. A table: "I want to change X" on the left, "look in Y" on the right. 5. Things that look wrong but are on purpose. Then things that really are wrong. 6. Three small, safe tasks for my first week that would teach me the most. If the code I pasted is not enough to answer something, tell me which file you would need. Do not guess.
In one paragraph. This is a bookings app for small gyms. A React front end talks to an Express API in /server. Data lives in Postgres and is accessed through Prisma. Anything slow (emails, PDF invoices) goes through a job queue in /jobs so that requests stay fast.
web/src/pages/ClassPage.tsx calls POST /api/bookings.server/routes/bookings.ts validates the body with bookingSchema, then calls canBook(member, class).server/services/bookings.ts opens a transaction, checks the class is not full, and inserts the row.booking-confirmed job and returns 201.jobs/bookingConfirmed.ts sends the email a few seconds later.| I want to change... | Look in |
|---|---|
| Who is allowed to do what | server/auth/policies.ts |
| An email | jobs/emails/*.mjml |
| The database schema | prisma/schema.prisma, then run migrate dev |
| Prices and plans | server/config/plans.ts (not the database) |
deletedAt. Nothing is ever really deleted, so always query through db.active().utils/dates.ts mixes UTC and local time. Do not build on it. There is a ticket.TODO.md. You will learn how migrations work here.canBook(). There are edge cases nobody has written down.I could not see how payments work from these files. Send me server/services/billing.ts and I will add it to the tour.
NoteThis is an example. Results change between runs and model versions. Prompt Podium is a fan project and is not affiliated with Anthropic.
Your first days in an unfamiliar repository: a new job, an open source project you want to contribute to, or a codebase you inherited. It is also a fast way to write onboarding notes for the next person who joins.
Claude only sees what you paste. Treat the list of things that "really are wrong" as leads to check with a teammate, not as facts. The instruction to name missing files instead of guessing is the most important line in the prompt, so keep it when you adapt it.
Use the copy button above. The full text is included, nothing is cut off.
Everything highlighted in yellow is a placeholder. Swap it for your own topic, audience or data.
If the result helped, press the heart. Votes decide which prompts make the weekly top 10.
What the error means. Cannot read properties of undefined (reading 'map') means orders was undefined at the moment the component rendered. The array never arrived, or it arrived under a different name. Most likely causes 1...
Stop Claude from patching symptoms. This prompt makes it rank the likely causes, tell you what to check first, and only then write the fix.

A small pack of lightweight loading indicators built with pure CSS, each with a reduced motion fallback and one variable to change the colour.
Wrapping parts of your prompt in simple tags is one of the easiest ways to get more reliable answers from Claude. A practical guide with examples.
None of these cause an error message. They just make every answer a little worse. Here is how to spot each one and what to write instead.