AWS Builder Center

Steering Files: The Config Layer That Makes Your AI Coding Agent Actually Understand You

Every AI coding session starts from zero context. You repeat the same preferences, conventions, and standards over and over. Kiro's Steering Files fix this: markdown docs in .kiro/steering/ that the agent reads before writing a single line of code. Set your style once globally, override per-project, and use smart inclusion modes so context loads only when relevant. This post covers the full setup with real examples, team scaling patterns, and results from companies that cut months of work down to days.

You've told your AI assistant to use functional components. Again. For the 47th time. You've re-explained that tests go in  __tests__/ , that you use Prettier with semicolons, that your API responses follow a specific shape. Every. Single. Project.
This is the hidden tax of AI-assisted development. The agent starts from zero context every time. And when it doesn't know your standards, it guesses. Sometimes it guesses wrong. Then you spend more time correcting than you saved.
Kiro's answer to this problem is Steering Files, and once you set them up, you'll wonder how you ever coded without them.

What Steering Files Actually Are

Steering files are markdown documents that live in  .kiro/steering/  and give the AI persistent context about how you work. The agent reads them before it writes a single line of code. No prompting required. No copy-pasting your preferences into every conversation.
Think of it as  .editorconfig  for your AI agent. Or a  .bashrc  that follows you across projects.
Two scopes exist:
  • Workspace ( .kiro/steering/  in your project root): rules specific to that repo
  • Global ( ~/.kiro/steering/  in your home directory): rules that apply everywhere you code
When both exist, workspace wins on conflicts. This means you can set universal defaults globally and override per-project where needed.

The Real Power: Inclusion Modes

Most people discover steering files and dump everything into "always on" mode. That works, but Kiro supports four inclusion strategies that make things much more precise.
Always (default) — loaded into every interaction. Good for: coding style, security policies, naming conventions.
---
inclusion: always
---

File Match — loaded only when you're working on files that match a pattern. So your React component standards only show up when you're actually editing  .tsx  files.
---
inclusion: fileMatch
fileMatchPattern: "components/**/*.tsx"
---

Manual — available on-demand via  #filename  in chat. Perfect for heavy reference docs you only need occasionally (migration guides, troubleshooting runbooks).
---
inclusion: manual
---

Auto — Kiro decides whether to include it based on what you're asking. You provide a description, and the agent matches it against your request. Like a skill that activates itself when relevant.
---
inclusion: auto
name: api-design
description: REST API design patterns and conventions. Use when creating or modifying API endpoints.
---

This means a 200-line API design guide doesn't pollute your context when you're writing a CSS component. It only shows up when you actually need it.


What Goes in a Steering File

Here's what I keep in mine, with full examples you can copy.

 ~/.kiro/steering/style.md  (global)

---
inclusion: always
---

# Coding Style

## TypeScript
- Always use strict mode (`"strict": true` in tsconfig)
- Prefer `interface` over `type` for object shapes
- Use named exports, never default exports
- Import order: node builtins → external packages → internal modules → relative imports
- Use `const` by default, `let` only when reassignment is needed

## React
- Functional components only, no class components
- Props interface named `{ComponentName}Props`
- Custom hooks prefixed with `use` and extracted to `hooks/`
- Prefer composition over prop drilling — use context sparingly

## Formatting
- Prettier with semicolons, single quotes, 100 char line width
- Trailing commas in multiline structures
- No unused imports or variables (enforced by ESLint)


 ~/.kiro/steering/testing.md  (global)

---
inclusion: always
---

# Testing Standards

- Framework: Vitest for unit tests, Playwright for e2e
- Test files live in `__tests__/` directories, mirroring source structure
- Use `describe` / `it` blocks, never standalone `test()`
- Minimum 80% coverage on new code, 60% on legacy
- Mock external dependencies, never real network calls in unit tests
- Prefer `userEvent` over `fireEvent` in component tests
- Name tests as behavior: `it('should reject expired tokens')` not `it('test auth')`


 .kiro/steering/api-patterns.md  (workspace, conditional)

---
inclusion: fileMatch
fileMatchPattern: ["**/api/**", "**/routes/**", "**/*.controller.ts"]
---

# API Design Patterns

## Response Envelope
All API responses use this shape:

#[[file:src/types/api-response.ts]]

## Error Handling
- Always return structured errors: `{ code: string, message: string, details?: object }`
- Use HTTP status codes correctly: 400 for validation, 401 for auth, 403 for permissions, 404 for not found
- Never expose stack traces in production responses

## Authentication
- JWT tokens in `Authorization: Bearer` header
- Middleware validates token before route handler executes
- Refresh tokens stored in httpOnly cookies, never localStorage

## Pagination
- Cursor-based pagination for lists: `{ cursor?: string, limit: number }`
- Default limit: 20, max limit: 100
- Response includes `nextCursor: string | null`


 .kiro/steering/migration-v3.md  (workspace, manual)

---
inclusion: manual
---

# V2 → V3 Migration Guide

Reference this file with `#migration-v3` when working on migration tasks.

## Breaking Changes
- `createClient()` now requires explicit region parameter
- Event handlers moved from callback style to async iterators
- Config files renamed from `.foorc` to `foo.config.ts`

## Migration Steps
1. Update package to ^3.0.0
2. Replace `createClient()` → `createClient({ region: 'us-east-1' })`
3. Convert event callbacks to `for await (const event of client.events())`
4. Rename config files and update to TS format
5. Run `npx foo-migrate --check` to validate


 ~/.kiro/steering/writing-voice.md  (global, auto)

---
inclusion: auto
name: writing-voice
description: Personal writing style and tone guidelines. Use when generating documentation, blog posts, commit messages, or any user-facing text.
---

# Writing Voice

- Direct, concise sentences. No filler phrases ("it's worth noting", "let's dive in")
- Active voice by default
- Technical terms without dumbing down, but explain acronyms on first use
- Commit messages: imperative mood, 50 char subject, blank line, body if needed
- PR descriptions: what changed, why it changed, how to test
- Comments in code: explain WHY, not WHAT (the code shows what)


Real-World: Product Team Toolkit (aws-samples)

AWS published a  complete steering setup for product teams  that shows how far you can push this. Their  .kiro/steering/  folder contains:
.kiro/steering/
├── product-workflow.md (always — main orchestration)
├── design-standards.md (always — visual standards)
├── market-research.md (manual — deep research guide)
├── prfaq-guide.md (manual — PRFAQ creation)
├── prd-guide.md (manual — PRD + tech research)
├── prototype-spec-guide.md (manual — interaction spec)
├── prototype-guide.md (manual — prototype creation)
└── specialist-*.md (fileMatch — auto-injected per output type)

The workflow goes  Discovery → Market Research → PRFAQ → PRD → Prototype , with each phase producing HTML deliverables. The specialist files use  fileMatch  so that when you edit a  Screen_*.html , the prototype specialist steering loads automatically. When you're working on  PRD_*.html , the PRD specialist kicks in instead.
This is steering as a full product development methodology, not just coding preferences.

Real-World Results: What Teams Are Reporting

The numbers from real teams using Kiro's spec-driven + steering workflow are striking:
Loyola Marymount University — A two-person cloud team updated 500 Lambda functions across dozens of AWS accounts. What previously took two months now takes half a day. The team lead described it as having "a three-to-ten-person development team at my fingertips."
Siemens — Completed a production-ready AWS serverless guardrail service (authentication, real-time dashboards, complete infrastructure) in 2 weeks with a single architect. The project traditionally required 3-4 months with multiple developers.
ALO Tech Solutions — Cut prototyping and iteration cycles by 30-40% using the spec + steering workflow.
Trailflow Systems — Went from weeks to days when building complex logistics features (dispatch, tracking, payroll).
Study From Experts — Built a full CRM for under $5 in token costs using Kiro with steering files guiding the entire architecture.
These aren't AI demos. They're production deployments where steering files ensured the agent understood the existing architecture, security requirements, and team conventions from the start.

Advanced Pattern: Writing Style Extraction

Giuseppe Battista (AWS Senior SA) shared a powerful pattern: use Kiro to analyze your past articles and blog posts, then generate a steering file that captures your writing voice. The result is a  writing-voice.md  that makes every piece of generated text sound like you wrote it.
The workflow:
  1. Point Kiro at 5-10 of your best articles
  1. Ask it to extract patterns: sentence length, vocabulary choices, paragraph structure, how you introduce concepts
  1. Save the output as  ~/.kiro/steering/writing-voice.md  with  inclusion: auto 
  1. Every time you ask Kiro to write docs, PR descriptions, or blog drafts, it matches your voice
This solves the "AI slop" problem without manually editing every output.

Advanced Pattern: Team Onboarding via dotkiro

The Kiro Labs team (internal open-source at AWS) built  dotkiro , a CLI that keeps your team's steering files in sync across all developer machines. Think of it as a package manager for AI context:
# Developer runs during onboarding
dotkiro sync --team frontend --org acme

# Updates propagate automatically
dotkiro pull

Combined with Git-based version control, steering changes go through the same PR review process as code changes. Because that's what they are: changes to how your team's AI agent behaves.

Headless Mode: Steering Beyond the IDE

With Kiro CLI, steering files aren't just for interactive coding. You can run agents headlessly in CI/CD or cron jobs, and they'll still read your steering:
# Scheduled report generation — steering ensures consistent format
kiro-cli chat --non-interactive "write a report about deployment metrics this week"

# PR review bot — steering defines your team's review standards
kiro-cli chat --non-interactive "review the diff in this PR for security issues"

Your steering files become the behavioral contract for every automated agent in your pipeline.

File References: Living Documentation

Steering files can link to actual files in your workspace:
Follow the patterns established in the base component:
#[[file:components/ui/button.tsx]]

API responses must match this OpenAPI spec:
#[[file:api/openapi.yaml]]

This means your steering stays current with your code. When  button.tsx  evolves, the agent sees the latest version automatically. No manual syncing.

Scaling to Teams

This is where steering gets interesting for organizations. Since global steering just reads from  ~/.kiro/steering/ , you can populate that folder from anywhere:
  • A shared git repo that devs clone during onboarding
  • MDM tools (Jamf, Intune) that push files to every laptop
  • A setup script that symlinks from a central location
#!/bin/bash
git clone git@github.com:yourco/kiro-steering.git /opt/company/steering
ln -sf /opt/company/steering/* ~/.kiro/steering/

Now every developer on the team starts with the same security policies, architecture principles, and coding standards baked in. New hires write code that matches your conventions from day one. No onboarding doc they'll forget to read. The AI enforces it by default.

Why This Matters More Than You Think

The AWS Well-Architected Agentic AI Lens actually calls out steering files as a best practice for configuration drift prevention. The idea: if you treat your AI agent's behavioral config with the same rigor as your infrastructure code, you get consistency across environments and developers.
This maps to a broader principle. In the old world, we standardized through linters, formatters, and code review. In the AI-assisted world, we also need to standardize the instructions we give the agent. Otherwise every developer gets different code from the same tool.
Steering files are that standardization layer.

Getting Started in 5 Minutes

  1. Create  ~/.kiro/steering/style.md 
  1. Write the one thing you repeat most often to your AI. For me it was: "Use TypeScript strict mode, functional components, named exports, and Vitest for testing."
  1. Start a new conversation in Kiro and ask it to create a component. Don't give it any style guidance.
  1. Watch it follow your preferences without being told.
That's the moment it clicks. You set context once. It persists forever. Your AI finally knows how you work.


Resources:
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article