[A-Z]+-[0-9]+ | Token | Description | |-------|-------------| | [A-Z]+ | One or more uppercase ASCII letters | | - | Literal hyphen | | [0-9]+ | One or more digits | 3.2 Enhanced Version with Word Boundaries To avoid matching substrings (e.g., XYZ-123 inside FOOXYZ-123BAR ), use word boundaries:
Jira Issue Key Regex May 2026
\b[A-Z]+-[0-9]+\b The simple regex above fails or behaves ambiguously in several real-world scenarios:
[A-Z]+-[0-9]+ | Token | Description | |-------|-------------| | [A-Z]+ | One or more uppercase ASCII letters | | - | Literal hyphen | | [0-9]+ | One or more digits | 3.2 Enhanced Version with Word Boundaries To avoid matching substrings (e.g., XYZ-123 inside FOOXYZ-123BAR ), use word boundaries: \b[A-Z]+-[0-9]+\b The simple regex above fails or behaves