For information about project and personal configuration locations, see the Project vs Personal Config page.
The firebender.json file must be located in the project root directory for project-wide configuration, or in ~/.firebender/firebender.json for personal configuration.

Fields

All high-level fields in the configuration are optional.

ignore

Type: string[]? Array of glob patterns for files that Firebender should not analyze without explicit permission. Example:
{
  "ignore": [
    "**/secrets.properties",
    "**/.env*",
    "private/**"
  ]
}
For details and examples, see Ignore Files.

mcpServers

Type: Object<string, ServerConfig>? Configure Model Context Protocol (MCP) servers to provide custom tools for Firebender Agent.

mcpServers.{serverName}

  • mcpServers.{serverName}.command: string? - The command to execute for the MCP server (required if url is not provided)
  • mcpServers.{serverName}.url: string? - The URL for HTTP-based MCP servers (required if command is not provided)
  • mcpServers.{serverName}.args: string[]? - Array of arguments to pass to the command
  • mcpServers.{serverName}.env: Object<string, string>? - Environment variables to set for the MCP server
  • mcpServers.{serverName}.headers: Object<string, string>? - HTTP headers for URL-based servers
Example:
{
  "mcpServers": {
    "brave-search": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-brave-search"],
      "env": {"BRAVE_API_KEY": "YOUR_API_KEY"}
    },
    "weather": {
      "command": "npx",
      "args": ["-y", "@h1deya/mcp-server-weather"]
    },
    "api-server": {
      "url": "http://localhost:3000/mcp",
      "headers": {"Authorization": "Bearer YOUR_TOKEN"}
    }
  }
}
Firebender follows the same syntax as Model Context Protocol. For details and examples, see MCP.

mcpEnvFile

Type: string? Optional path to a file containing environment variables for MCP servers. Can be either a full path or a relative path from the project root. Example:
{
  "mcpEnvFile": ".env.mcp"
}

rules

Type: (string | RuleConfig)[]? Define guidelines for Firebender to follow when generating code. Can contain both global rules (strings) and path-specific rules (objects).
  • rules[i]: string - A rule that applies to all files
  • rules[i].filePathMatches: string | string[]? - Optional glob pattern(s) to match file paths for specific rules. Can be a single pattern or an array of patterns.
  • rules[i].rules: string[] - Array of rules to apply only to matching files
  • rules[i].rulesPaths: string | string[] - Path(s) to files containing additional rules. Can be either a single path or an array of paths. Paths can be absolute or relative to the project root.
Example:
{
  "rules": [
    "Follow Material Design 3 guidelines",
    "Use Kotlin coroutines for async operations",
    {
      "filePathMatches": "**/*Test.kt",
      "rules": ["Use Kotest BDD style", "Prefer property-based testing"],
      "rulesPaths": "test-rules.txt"
    },
    {
      "filePathMatches": ["**/*.kt", "**/*.kts"],
      "rulesPaths": ["/absolute/path/to/rules.txt", "relative/path/to/more-rules.txt"]
    }
  ]
}
For details and examples, see Rules for AI.

commands

Type: CommandConfig[]? Define custom commands that can be executed through Firebender’s interface. Commands are markdown files containing prompts or instructions for the AI.

CommandConfig

  • name: string - The name of the command as it appears in the UI
  • path: string - Path to the command file. Supports ~ expansion for home directory, absolute paths, and relative paths (relative to project root for project config, ~/.firebender for personal config)
Example:
{
  "commands": [
    {
      "name": "Generate Firebender Rules",
      "path": "./prompts/generate-rules.md"
    },
    {
      "name": "Write Commit Message",
      "path": "~/firebender-commands/commit-message.md"
    },
    {
      "name": "Code Review",
      "path": "/home/user/.firebender/commands/code-review.md"
    }
  ]
}