Write instructions your agent will follow

ComputerWeb app3 min readUpdated October 3, 2026

Project instructions reach the agent in every conversation, so you stop repeating yourself. Here's what to put in them, what to leave out, and how to keep them working.

Each new conversation starts without what you told agents in earlier ones, including your preferences. Your project’s Instructions fix that. Enjoy sends them to the agent at the start of every conversation in the project, whichever agent you use, and updates running conversations on their next message after you change them.

Why it helps

Claude Code’s documentation calls instruction files “the place you write down what you’d otherwise re-explain.” They also hold up better in long conversations. When an agent summarizes older messages to make room, rules you only typed in chat can get lost. Claude Code and Codex receive your project’s instructions as standing instructions, separate from the chat messages that get summarized.

How to do it

  1. Open your project’s settings. Select Project settings, at the right end of the bar below the project tabs.
  2. Open Instructions. It shows None until you add some, then Custom.
  3. Write your rules in the box, then select Save.

To start over, select Clear instructions, then Save.

Claude Code also reads a file called CLAUDE.md in your project folder, and Codex reads AGENTS.md. Recent versions of Claude Code read AGENTS.md too when there’s no CLAUDE.md. Those files live with your project’s code, so they travel with it. Enjoy’s Instructions apply to every agent you use in this project. Either works. Keep the same rule in only one place, so they can’t disagree.

What to put in them

Write down what the agent can’t work out by reading your project, using the guidance from Claude Code’s and Codex’s documentation:

  • What the project is and who it’s for. One or two sentences.
  • How to check work. For example, “Check every change in the browser at phone size before saying it’s done.” Codex’s guide lists “what done means and how to verify work” among the things to include.
  • Rules and no-go areas. “Don’t change prices or the checkout without asking me first.”
  • How you want to hear back. “Explain what you changed in plain language, without code.”
  • Mistakes you’ve corrected twice. Claude Code suggests adding a rule when the agent “makes the same mistake a second time.”

Be concrete. Claude Code’s documentation suggests instructions “concrete enough to verify,” such as “Run npm test before committing” instead of “Test your changes.”

An example

This is the booking website for my yoga studio. Most visitors use phones.

  • Check every change in the browser at phone size before you say it’s done.
  • Commit your changes when you finish a task, with a short description.
  • Ask me before changing prices, payments, or anything customers have already booked.
  • Our colors and tone of voice are in the doc “Brand guide”.
  • End each task with a plain-language summary of what changed. No code.

When the agent repeats a mistake, ask it for help: “What should I add to the project instructions so you don’t do that again?” OpenAI’s Codex guide recommends this kind of retrospective.

Common pitfalls

  • Writing too much. Claude Code’s documentation says long files “reduce adherence” and recommends staying under 200 lines. Codex’s says “a short, accurate AGENTS.md is more useful than a long file full of vague rules.”
  • Vague rules, like “write good code.” The agent already tries to.
  • Rules that contradict each other. Claude Code warns that the agent “may pick one arbitrarily.”
  • Treating instructions as locks. Agents treat them as guidance, not enforcement. To stop an agent from changing files at all, use a stricter permission mode. See Choose what your agent can do without asking.
  • Putting passwords or keys in them. Instructions go to your AI provider with every conversation. See Keep passwords and API keys safe.
Did this help?

Still need a hand?

Email help@enjoy.dev with your computer, your Enjoy version, and what happened. Leave out passwords and sign-in codes. For questions and ideas, join our Slack community .