Skip to content New: the Claude Skills catalog — what each skill does and how to install it →
SP-00 · Reference · rev. 10/2026

System prompts

A system prompt is the standing instruction a model reads before your message: who it is, who it serves and how to answer. Here is how it differs from a user prompt, where each product lets you set one, and what Anthropic and OpenAI publish about their own.

LevelBeginner to intermediate
CoversChat apps, coding agents, APIs
IncludesFill-in template
CheckedOct 2026

A system prompt is a set of instructions that sits above the conversation and shapes every reply. Apps use one to give the model the date, a role and house rules before you type anything. You can write your own in the APIs. The chat apps offer close equivalents under names such as custom instructions and project instructions, and coding agents read them from project files such as CLAUDE.md and AGENTS.md. This page explains the idea, shows where to set one in each product, and gives a template to start from.

What a system prompt is

Each vendor describes the same mechanism in its own words.

  • Anthropic exposes a system parameter in its Messages API. Its prompting guide says setting a role in the system prompt "focuses Claude's behavior and tone for your use case", and that even a single sentence makes a difference.
  • OpenAI uses message roles. In its API guide, developer messages are "instructions provided by the application developer, prioritized ahead of user messages". The instructions parameter gives "high-level instructions on how it should behave", and these "take priority over a prompt in the input parameter".
  • Google calls them system instructions. The Gemini API takes a system_instruction parameter (systemInstruction in some SDKs) to guide the model's behavior.

OpenAI's Model Spec formalizes the ordering as a chain of command with authority levels, from the highest down: root, system, developer, user and guideline. Higher levels supersede lower ones. In plain terms, a system or developer instruction beats a conflicting user request.

System prompt vs user prompt

System promptUser prompt
Who writes itThe app builder, or you in settingsYou, in the chat box
When it appliesEvery turn of the conversationThe current request
Priority on conflictHigherLower
Typical contentRole, audience, tone, rules, format, background factsThe task and its input

A good split: anything you would repeat in every message goes in the system prompt; the specific job goes in the user prompt. Context engineering covers this split in depth, and prompt engineering covers the user-prompt side.

Where to set one, product by product

ProductFeatureWhereApplies to
ChatGPTCustom instructionsSettings, PersonalizationAll chats
ChatGPTProject instructionsProject menu, Project settingsChats in that project; overrides custom instructions
ChatGPTGPT instructionsCreate a GPT, Configure tab, InstructionsEvery chat with that GPT
Claude appInstructions for ClaudeYour initials, SettingsAll conversations
Claude appProject instructionsInside a project, "Set project instructions"Chats in that project
Gemini appYour instructions for GeminiSettings & help, Personal contextAll chats
Gemini appGemsExplore Gems, New GemChats with that Gem
Claude CodeCLAUDE.md, --append-system-prompt, --system-promptProject files and CLI flagsSessions in that project, or one run
CodexAGENTS.md~/.codex/AGENTS.md (global), plus AGENTS.md files from the repository root down to the current folderEvery run; files closer to the current folder take precedence
CursorRulesProject Rules in .cursor/rules, User Rules in settings, or AGENTS.md in the project rootAdded at the start of the model context when a rule applies
Anthropic APIsystemMessages API requestThat request
OpenAI APIinstructions or a developer messageAPI requestThat request
Gemini APIsystem_instructionAPI requestThat request

Two notes. ChatGPT custom instructions are capped at 1,500 characters on Free and Go and 5,000 on Plus, Pro, Business, Enterprise and Edu. In Claude Code, --system-prompt replaces the default prompt entirely, while --append-system-prompt adds your text to the end of it and keeps the built-in instructions. The ChatGPT cheat sheet and Claude Code cheat sheet list the related settings.

A system prompt template

The structure below follows Google's advice for Gem instructions (persona, task, context, format) and OpenAI's advice for GPT instructions: explicit steps, positive instructions over long lists of prohibitions, and brief examples when the GPT must apply a definition.

Try it
Role: You are [role, for example a support agent for an accounting app].
Audience: You are talking to [who, and what they already know].
Goal: Help them [main outcome] so that [why it matters].
How to answer:
1. [first step, for example confirm which plan they are on]
2. [second step]
3. [what to do when you are unsure, for example say so and point to the help page]
Format: [length, structure, reading level].
Tone: [two or three adjectives].
Facts you can rely on:
[paste product facts, policies or definitions]
Example of a good answer:
[one short sample reply]

If you would rather start from a draft, the AI prompt generator builds a structured prompt from a short description.

How to write one that works

  • Explain the reason behind a rule. Anthropic's guide shows that "your response will be read aloud by a text-to-speech engine, so never use ellipses" works better than "NEVER use ellipses", because the model generalizes from the reason.
  • Drop the shouting. Anthropic notes that Claude Opus 4.5 and Opus 4.6 respond more strongly to the system prompt than earlier models, and that prompts written with "CRITICAL: You MUST" can now cause overtriggering. Plain wording such as "Use this tool when..." is its suggested fix.
  • Put steps in order. OpenAI's GPT guidance favors "When X happens, do Y" structure for multi-step workflows, with headings and lists so priorities stand out.
  • Show one example. A sample answer fixes format faster than a paragraph describing it. See few-shot prompting.
  • Paste the facts in. Include the policy, price list or definitions the assistant must use, so it does not rely on what it remembers from training.

What vendors publish about their own system prompts

Anthropic publishes the system prompts used by claude.ai and the Claude mobile apps in its release notes, with a page per model. The list runs from Claude Haiku 3 to Claude Sonnet 5.5 and Claude Opus 5.5 as of October 2026. Anthropic says the prompt gives Claude up-to-date information such as the current date at the start of every conversation, and encourages behaviors such as providing code snippets in Markdown. It is updated periodically, and these updates do not apply to the Claude API. From the Claude 4.6 generation on, each model ID is a single fixed snapshot, so those models have one entry each.

OpenAI publishes the Model Spec, which sets out how its models weigh instructions from different roles. It describes the rules for system, developer and user messages; it is not a copy of the ChatGPT system prompt.

xAI keeps a public GitHub repository with the system prompts it uses for the Grok chat assistant and the @grok bot on X, and says it updates it regularly. If you are looking for the Grok system prompt, that repository is the primary source.

We do not reprint "leaked" system prompts. A copy posted by a third party cannot be checked against the vendor's own text, while the prompts Anthropic and xAI publish are available at the sources linked below.

FAQ

What is a system prompt in an LLM?

Instructions given to a model before the conversation that apply to every reply: its role, rules and format. Anthropic's API takes them in the system parameter, OpenAI's in instructions or developer messages, and Gemini's in system_instruction.

Are custom instructions the same as a system prompt?

They play a similar role. ChatGPT applies custom instructions to all chats, and Claude applies "Instructions for Claude" to all conversations. The apps also keep their own system prompts, which you do not edit.

Does Claude's published system prompt apply to the API?

No. Anthropic states that the system prompt updates in its release notes do not apply to the Claude API.

Can a user override a system prompt?

Not by design. OpenAI's Model Spec ranks system and developer instructions above user instructions, and OpenAI's API guide says developer messages are prioritized ahead of user messages.

Sources

  1. System prompts (release notes) — Anthropic, accessed October 2026
  2. Prompting best practices — Anthropic, accessed October 2026
  3. Prompt engineering — OpenAI API docs, accessed October 2026
  4. OpenAI Model Spec (2026-08-18) — OpenAI, accessed October 2026
  5. Text generation — Google AI for Developers, accessed October 2026
  6. ChatGPT Custom Instructions — OpenAI Help Center, accessed October 2026
  7. Projects in ChatGPT — OpenAI Help Center, accessed October 2026
  8. Creating and editing GPTs — OpenAI Help Center, accessed October 2026
  9. Understanding Claude's personalization features — Claude Help Center, accessed October 2026
  10. How can I create and manage projects? — Claude Help Center, accessed October 2026
  11. Customize Gemini's responses with your instructions — Gemini Apps Help, accessed October 2026
  12. Tips for creating custom Gems — Gemini Apps Help, accessed October 2026
  13. CLI reference — Claude Code Docs, accessed October 2026
  14. Custom instructions with AGENTS.md — OpenAI Codex docs, accessed October 2026
  15. Rules — Cursor Docs, accessed October 2026
  16. grok-prompts — xAI on GitHub, accessed October 2026
Weekly

New prompts in your inbox

One email a week: the best new prompts and one short guide. Unsubscribe any time.