A system prompt is a set of instructions you give an AI model once, before any conversation starts, that shapes how it behaves throughout that session. Instead of explaining your role, preferences, and constraints at the start of every chat, you set them once in a system prompt and the model applies them automatically. It's the difference between repeating yourself every session and having a persistent working context.
What a system prompt is
In consumer chat interfaces (Claude.ai, ChatGPT), system prompts often appear as "custom instructions" or "memory" settings. In the API, they're a distinct message role — the system parameter — that sits above the conversation.
When you write a system prompt, you're essentially configuring the model's behavior for an extended context. The model reads it at the start of every conversation and uses it to shape its responses throughout.
What to put in a system prompt
The most useful system prompts include:
Who you are: "I am a marketing consultant specializing in B2B SaaS. My clients are typically software companies with 10-200 employees."
How you want responses formatted: "Keep responses concise unless I explicitly ask for detail. Use bullet points for lists. Don't use excessive headers for short answers."
Your preferences and constraints: "I prefer direct, opinionated responses over hedged ones. If you're uncertain, say so briefly and give your best answer anyway."
What to avoid: "Don't start responses with sycophantic phrases like 'Great question!' or 'Certainly!'. Don't add unnecessary caveats to straightforward requests."
Your domain context: "I work primarily in JavaScript, TypeScript, and Python. When giving code examples, default to TypeScript unless I specify otherwise."
System prompts in Claude vs ChatGPT
In Claude.ai, custom instructions work as a persistent system-level context. Claude responds particularly well to system prompts that are specific, structured, and include explicit format requirements. XML tags in system prompts (defining sections like <persona>, <rules>, <format>) work especially well.
In ChatGPT, custom instructions allow you to set "what you'd like ChatGPT to know about you" and "how you'd like ChatGPT to respond." GPT-5.5 follows system prompt instructions reliably and is particularly good at sticking to requested formats.
Via the API, system prompts give you full control — you can write detailed multi-paragraph instructions without UI constraints. This is how developers building AI-powered applications set their application's behavior.
A useful template
You are [role description].
Context: [Relevant background about the user's work, domain, or situation]
Always:
- [Behavior to maintain throughout]
- [Preferred format or response style]
Never:
- [Behavior to avoid]
- [Patterns to exclude from responses]
When asked about [specific topic], [specific guidance].
Example:
You are an AI assistant for a software development consultant.
Context: My work involves Python, TypeScript, and AWS. Clients range from
early-stage startups to mid-size companies.
Always:
- Give direct recommendations, not "it depends" answers unless the tradeoff
genuinely requires it
- Show code examples when explaining technical concepts
- Keep explanations practical and implementation-focused
Never:
- Use jargon without explaining it
- Start responses with "Great question!" or similar phrases
- Over-caveat straightforward technical answers
When asked about architecture decisions, ask about scale and team size
before recommending solutions.
How much does it help?
A lot. The difference between a model that has well-configured custom instructions and one that doesn't is visible in every conversation — you stop re-explaining your context, the formatting is consistent, and the model's default assumptions match your actual situation.
For anyone who uses AI for professional work daily, setting up useful custom instructions is worth 15 minutes of one-time effort.
The limit
System prompts don't give the model information about what happened in previous sessions (unless you're using memory features). Each conversation starts fresh with only the system prompt as context. For long-running projects or ongoing relationships, you'll still need to provide session-specific context beyond what's in the system prompt.