# key (issuekey) field in JQL: syntax and examples

URL: https://goingstellar.ro/reference/jql/issuekey-field/

The key field matches a work item by its key, like WEB-25. It takes lists, ranges within one project, and pattern matches. The Atlassian docs call it work item key and give the name workItemKey, with aliases id, workItem and key. In JQL on Cloud the old names issuekey and issue work as well.

## Syntax

```
key = WEB-25
key IN (WEB-1, WEB-25)
key >= WEB-20
key ~ "WEB*"
```

## Works with

- Fields: aliases key, issuekey, issue, id, workItemKey, workItem
- Operators: =, !=, >, >=, <, <=, ~, !~, IN, NOT IN
- Functions: with IN and NOT IN, issueHistory() and workItemHistory(), linkedIssues(), watchedIssues(), votedIssues()
- Not with: IS, IS NOT, WAS, WAS IN, WAS NOT, WAS NOT IN, CHANGED

## Examples

```
key in (WEB-1, WEB-25, MOB-2)
```

A hand-picked set of items from two projects. The usual way to turn a list from a meeting note into a filter. Run on Jira Cloud on 2026-11-29.

```
project = WEB AND key >= WEB-20 ORDER BY key ASC
```

WEB work from number 20 onward in key order. A cheap way to see everything created after a known item. Run on Jira Cloud on 2026-11-29.

```
key > WEB-5 AND key <= WEB-10 AND project = WEB
```

A numbered slice of one project, for a review of the items that were created around the same time. Run on Jira Cloud on 2026-11-29.

```
key in linkedIssues(WEB-25)
```

The items linked to WEB-25. Because the key field accepts the function, you can mix it with other clauses. Run on Jira Cloud on 2026-11-29.

```
key not in (WEB-1, WEB-2) AND project = WEB
```

The whole project without two known items, for example ones you already handled in another report. Run on Jira Cloud on 2026-11-29.

```
key ~ "-25"
```

Every key that ends in number 25, in any project. The pattern ignores the project part, so this finds WEB-25 and SCRUM-25 alike. Run on Jira Cloud on 2026-11-29.

## Pitfalls

- A key that does not exist stops a plain comparison: `key = WEB-99999` and `key = NOPE-1` both return "Issue does not exist or you do not have permission to see it." So does a bare number such as `key = 25`. Inside a list the missing key is skipped, and `key in (WEB-1, WEB-99999)` returns WEB-1 (checked on Jira Cloud, November 2026).
- Ranges work per project. `key > WEB-5` compares the number part and only returns WEB items, never MOB or SCRUM ones. Order is numeric, so `ORDER BY key DESC` puts WEB-34 before WEB-5 (checked on Jira Cloud, November 2026).
- The new function names in the docs fail. `key in linkedWorkItems(WEB-25)` returns "Unable to find JQL function 'linkedWorkItems(WEB-25)'." The working name is `linkedIssues()`. In contrast, `issueHistory()` and `workItemHistory()` both run.
- No `IS EMPTY` and no history: `key is EMPTY` returns "The operator 'is' is not supported by the 'key' field." and `key was WEB-1` returns "History searches do not support the  'key' field." Key matching is not case sensitive, so `key = web-25` finds WEB-25.

## Questions and answers

### Is it key, issuekey, issue or workItemKey in JQL?

All of them run on Jira Cloud as names for the same field. The docs use workItemKey and list id, workItem and key as aliases. The classic names issuekey and issue also work.

### Can I search for a range of keys in JQL?

Yes, inside one project: key >= WEB-20 AND key <= WEB-30 AND project = WEB. The comparison uses the number part.

## Related

- [linkedIssues()](https://goingstellar.ro/reference/jql/linkedissues/)
- [issueHistory()](https://goingstellar.ro/reference/jql/issuehistory/)
- [watchedIssues()](https://goingstellar.ro/reference/jql/watchedissues/)
- [IN](https://goingstellar.ro/reference/jql/in-operator/)
- [CONTAINS (~)](https://goingstellar.ro/reference/jql/contains-operator/)
- [parent](https://goingstellar.ro/reference/jql/parent-field/)

## Sources

- [JQL fields (Atlassian Support, Jira Cloud)](https://support.atlassian.com/jira-software-cloud/docs/jql-fields/)

