AI Tools › Guides › Write a good prompt
How to Write a Good Prompt for an AI
A good prompt is not a magic formula: it is a clear request with the context and format you want.
In short
Here is a five-step method, with a before and after.
- Say what you want in one sentence.
- Give the useful context.
- Set measurable constraints.
- Require a response format.
- Show an example if style matters.
When an AI answers off target, the problem almost always comes from the request, rarely from the tool. The official documentation agrees: OpenAI advises being specific about context, expected outcome, length, format and style, and Anthropic compares its AI to a brilliant new colleague who does not know your habits: the more precisely you explain, the better the result.
This page offers a method that works with any chat AI. If you would rather fill in a form, the prompt generator tool applies the same steps.
How to do it
- Say what you want in one sentence. Start with the instruction, before anything else. “Write,” “compare,” “fix,” “explain” work better than “I might like something about.”
- Give the useful context. Who is it for? In what situation? What do you already know? Paste the working text instead of describing it.
- Set measurable constraints. Replace “fairly short” with “120 words maximum”; “a friendly tone” with “casual, no jargon.”
- Require a response format. A table, a numbered list, three paragraphs, a two-level outline: the AI readily follows an explicit format.
- Show an example if style matters. A short model sentence or an excerpt of what you like guides better than a long adjective.
Before and after on a real case
Imagine you need to announce a homeowners association meeting to your neighbors. Here is a request as people naturally write it:
Write an email for the meeting.
The AI knows neither who is writing, nor to whom, nor when, nor in what tone. It will make things up or stay generic. Here is the same request with the five steps:
Write an email inviting residents to the annual meeting of our homeowners association. Context: I am the president of the board of a 24-unit building. The meeting is on [date] at [time], in the [location] room. Agenda: vote on the budget, replacing the intercom, the question of bikes in the lobby. Constraints: 150 words maximum, formal address, friendly but direct tone, no pompous phrases. Ask people to confirm attendance before [deadline]. Format: an email subject line, then the body of the message with the agenda as a bulleted list.
The second version is not more “intelligent”: it simply contains the information that was missing. That is what changes everything.
The most common mistakes
- Putting everything in one request. If you want an outline, a text and a proofread, go step by step in the same conversation.
- Saying what not to do. OpenAI recommends stating what to do instead: “write in short sentences” rather than “don't write long sentences.”
- Forgetting the audience. A text for a ten-year-old and a text for a chief financial officer are not written the same way.
- Accepting the first answer. A prompt can be corrected: follow up with “make it shorter,” “more concrete,” “add an example.”
- Not checking. An AI can be confidently wrong. Reread, especially numbers, dates and names.
Iterate rather than aim for perfection
Google's documentation for Gemini suggests rephrasing, reordering elements or changing the angle when the result does not fit. Get into the habit of reading the answer for what is missing, then adding one line of clarification. Three back-and-forths almost always beat one huge prompt written in one go.
Thanks. Keep the structure, but: 1. shorten the introduction to a single sentence; 2. replace “Dear neighbors” with a more neutral greeting; 3. add as the last line the number to call if someone cannot attend: [number].
A second example, in another field
The method also works for an analysis task. Here, you want to understand a difficult text:
Here is an excerpt from a rental lease that I do not understand: ### [paste the excerpt, without names or addresses] ### Explain it to me in plain language, clause by clause. For each clause, tell me in one sentence what it requires me to do and what it allows the other party to do. End with the list of points where I should ask a professional a question. If a passage is ambiguous, say so instead of guessing.
Notice three things: the ### delimiter clearly separates the instruction from the text (OpenAI advises using delimiters), the format is specified, and the AI is allowed to flag an ambiguity. This reduces the risk of an invented answer. For any personal legal, medical or financial question, the AI helps you understand but does not replace a professional.
To remember before you hit send
Reread your prompt as if you were handing it to a colleague who was not there: would they understand the task, the audience and the format? If not, add what is missing. To go further depending on the tool, see our guides for Claude and for Gemini, or test your draft with the prompt improvement tool. And never paste personal or confidential data into a conversation if you can replace it with brackets.
Frequently asked questions
Do prompts need to be very long?
No. Length matters less than precision. A few lines with goal, context, constraints and format are often enough. A long but confusing prompt gives worse results than a short, sharp one.
Should I start with “you are an expert”?
Giving a role can steer the tone and level of detail, and Anthropic's documentation mentions it as a useful technique. But a role without context or precise instructions does not replace a good request.
Does a good prompt work on every AI?
The principles (clarity, context, format, examples) are shared. Each tool has its own habits, which is why we have separate guides for Claude and Gemini.
How do I know if my prompt is good?
Test it: is the answer usable without rewriting it entirely? If not, spot what is missing (audience, format, length) and add it.
Sources: OpenAI Help: best practices for prompt engineering · Anthropic documentation: prompting best practices · Google: prompting strategies for Gemini. Guide updated on November 23, 2026.
Free tools to go faster
- Prompt generatorFill in a few fields, or pick a template if you like: your prompt builds itself as you type, ready to copy.
- Prompt improverPaste your prompt: the tool checks 12 points and tells you what to add to get better answers.
Ready-to-copy prompts
On the same topic
- How to Write a Good Prompt for Claude
- How to Write a Good Prompt for Gemini
- 12 ChatGPT Prompt Examples to Copy and Adapt
- Why ChatGPT Gives Bad Answers (and How to Fix It)