Skills vs MCP vs Subagents vs Cursor Rules

What each one loads, when it loads and what it costs in context, from the Claude Code, Codex and Cursor docs. With a table for picking one.

· 5 min read · Skillland

GuidesAuthoring

Skills, MCP servers, subagents, rules files and AGENTS.md all change what a coding agent does, and they overlap enough to be confusing. The useful question for each one is: when does it load, and what does it put into the context window?

The short version

What it isWhen it loadsPick it for
Skill (SKILL.md)Instructions, reference files and scripts in a folderName and description at startup, the body when a request matches or you call itA procedure or reference you need some of the time
MCP serverA connection to an outside service that gives the agent toolsTool names at startup, full schemas when usedReading or changing data the agent can't reach
SubagentA separate worker with its own context windowWhen it's started; only its summary comes backWork that reads a lot and returns a little
Cursor rule (.mdc)Instructions with a description, globs or alwaysApplyEvery chat, on matching files, or when the agent finds it relevantConventions tied to file types or folders
AGENTS.md / CLAUDE.mdOne Markdown file of project instructionsEvery sessionFacts every task needs: build commands, conventions

The rest of this post is the detail behind each row.

Skills

A skill is a folder with a SKILL.md file that follows the Agent Skills specification. At startup the agent sees only the name and description. When a request matches the description, or you call the skill by name, the agent reads the full body.

The Claude Code docs put the cost as "Descriptions at start, full content when used". That's why a skill can hold long reference material that a CLAUDE.md file can't. The skills docs say "a skill's body loads only when it's used, so long reference material costs almost nothing until you need it".

The cost that remains is the descriptions. Claude Code cuts each skill's listing at 1,536 characters, and Codex caps the whole list: "By default, this list uses at most 2% of the model's context window, or 8,000 characters when the context window is unknown" (OpenAI: build skills). A hundred installed skills with long descriptions compete for that space.

Skills are also the one format here that works in all three agents unchanged.

MCP servers

MCP connects the agent to something outside it: a database, Slack, a browser, an issue tracker. The server provides tools, and handles the connection and sign-in.

Claude Code's comparison is direct: "MCP connects Claude to external services. Skills extend what Claude knows, including how to use those services effectively." It loads "Tool names; full schemas on demand".

The two work well together. The MCP server gives access to the database; a skill holds your schema notes and the queries you trust. If you're writing a skill that tells the agent to curl an API by hand on every run, an MCP server may be the better tool. If you're writing an MCP server whose tools need two paragraphs of usage notes, those notes belong in a skill.

Codex skills can declare the MCP servers they depend on, in agents/openai.yaml under dependencies.tools.

Subagents

A subagent runs in its own context window and hands back a summary. In Claude Code's words, subagents are "isolated workers that run separately from your main conversation", while skills are "reusable content you can load into any context".

Use one when a task would flood your conversation: searching a large codebase, reading a long log, reviewing many files. The subagent reads everything; your session gets the findings.

They combine in both directions. A Claude Code subagent can preload skills, and a skill with context: fork in its frontmatter runs inside a fresh subagent. A forked skill doesn't see your conversation, so its instructions have to stand on their own.

Cursor rules

Cursor's project rules live in .cursor/rules as .mdc files (Cursor: Rules). Three frontmatter fields decide when a rule applies:

FrontmatterWhen the rule applies
alwaysApply: true"Always included. Globs and description are ignored."
globs set"Auto-attached when a matching file is in context."
description only"Agent reads the description and pulls the rule in when relevant."
none of them"Included only when you @-mention the rule in chat."

A rule with only a description behaves a lot like a skill, and Cursor now treats it that way. Its /migrate-to-skills command "converts eligible dynamic rules and slash commands into Agent Skills": rules "with alwaysApply: false (or undefined) and no globs patterns" become skills (Cursor: Agent Skills). Always-on rules and rules with globs stay rules.

So in Cursor the split is roughly: rules for conventions that must always apply or that belong to certain files, skills for procedures the agent pulls in when needed. Skills can also be scoped to files with paths.

Claude Code has its own rules folder, .claude/rules/, which loads "Every session, or when matching files are opened", while skills load "On demand, when invoked or relevant".

AGENTS.md and CLAUDE.md

These are a single Markdown file of instructions that loads every session. AGENTS.md is the shared format; Cursor reads it "in the project root and subdirectories" and describes it as "a plain markdown file without metadata". Claude Code reads its own CLAUDE.md, and reads AGENTS.md instead when the repository has no CLAUDE.md (Claude Code memory docs).

Because the whole file is in every request, keep it short. Claude Code's guidance is to keep CLAUDE.md under 200 lines and to create a skill "when a section of CLAUDE.md has grown into a procedure rather than a fact". The conversion guide shows how to move those sections out.

Picking one

Ask these in order:

  1. Does the agent need to reach a system it can't see? Add an MCP server.
  2. Must it hold in every task? Put it in AGENTS.md or CLAUDE.md, or an always-apply rule. For something that must happen every time, such as blocking an edit to .env, Claude Code's docs point out that a hook is enforcement while an instruction "is a request, not a guarantee".
  3. Does it only matter for certain files? A Cursor rule with globs, a .claude/rules/ file with paths, or a skill with paths.
  4. Is it a procedure or reference needed some of the time? Write a skill.
  5. Will the work read far more than it returns? Run it in a subagent, or give the skill context: fork.

If you go with a skill, check it before you share it: the validator scores the description and structure against the spec and each agent's docs.

share