Back to docs
configuration

Tags Configuration

Configuring Tags

Tags help you categorize notes across workspaces. Configure auto-tagging via glob patterns in strayfiles.toml.

Basic Tag Configuration

[tags.urgent]
description = "High priority items"
include = ["**/urgent/**", "**/critical/**"]
color = "#EF4444"
icon = "alert"

[tags.reference]
description = "Reference documentation"
include = ["**/reference/**", "**/docs/**"]
exclude = ["**/drafts/**"]
color = "#10B981"

Tag Properties

PropertyTypeDescription
descriptionstringHuman-readable description
includearrayGlob patterns for auto-assignment
excludearrayGlob patterns to exclude (overrides include)
colorstringHex color for UI display
iconstringIcon name or emoji

Auto-Tagging with Globs

Files matching include patterns are automatically tagged:

[tags.api]
include = ["**/api/**", "**/endpoints/**"]

[tags.tests]
include = ["**/*_test.md", "**/*_spec.md", "**/tests/**"]

[tags.archive]
include = ["**/archive/**", "**/old/**"]
exclude = ["**/archive/keep/**"]

Frontmatter Tags

You can also assign tags directly in frontmatter:

---
strayfiles:
  enabled: true
  tags: [urgent, api, reviewed]
---

Union Merge Semantics

Tags are assigned from both config patterns and frontmatter:

Example:

Config:

[tags.docs]
include = ["**/docs/**"]

File at projects/docs/api.md:

---
strayfiles:
  tags: [api, reference]
---

Result: Note has tags docs (from config), api, and reference (from frontmatter).

Viewing Tag Sources

In the UI, you can see where each tag came from:

  • Config - Auto-assigned via glob pattern match
  • Frontmatter - Explicitly set in the file
  • Manual - Assigned via the UI

Tag Colors

Use hex colors for visual organization:

[tags.urgent]
color = "#EF4444"  # Red

[tags.in-progress]
color = "#F59E0B"  # Amber

[tags.done]
color = "#10B981"  # Green

[tags.idea]
color = "#8B5CF6"  # Purple

Tips

Project-specific tags:

Different projects can have different tag configurations in their local strayfiles.toml.

Combine with workspaces:

Use tags for cross-cutting concerns (status, type) and workspaces for organizational grouping (project, team).