You can search issues and pull requests by using search qualifiers in any combination to narrow your search results.

Tips:

  • This article contains example searches on the GitHub.com website, but you can use the same search filters on your GitHub Enterprise instance.
  • For a list of search syntaxes that you can add to any search qualifier to further improve your results, see "Understanding the search syntax".
  • Use quotations around multi-word search terms. For example, if you want to search for issues with the label "In progress," you'd search for label:"in progress". Search is not case sensitive.

Search issues or pull requests

By default, GitHub Enterprise search will return both issues and pull requests. However, you can restrict search results to just issues or pull requests using the type or is qualifier.

Qualifier Example
type:pr cat type:pr matches pull requests with the word "cat."
type:issue github commenter:defunkt type:issue matches issues that contain the word "github," and have a comment by @defunkt.
is:pr event is:pr matches pull requests with the word "event."
is:issue is:issue label:bug is:closed matches closed issues with the label "bug."

Scope the search fields

The in qualifier limits what fields are searched. With this qualifier you can restrict the search to just the title, body, comments, or any combination of these. Without the qualifier, the title, body, and comments are searched.

Qualifier Example
in:title warning in:title matches issues with "warning" in their title.
in:body error in:title,body matches issues with "error" in their title or body.
in:comments shipit in:comments matches issues mentioning "shipit" in their comments.

Search inside public and private repositories

If you're searching across all of GitHub Enterprise, it can be helpful to filter your results based on whether the repository is public or private. You can do this with is:private and is:public.

Qualifier Example
is:public is:public matches issues and pull requests in all public repositories.
is:private is:private cupcake matches issues and pull requests that contain the word "cupcake" in private repositories you have access to.

Search by the author of an issue or pull request

The author qualifier finds issues and pull requests created by a certain user or integration account.

Qualifier Example
author:USERNAME cool author:gjtorikian matches issues and pull requests with the word "cool" that were created by @gjtorikian.
bootstrap in:body author:mdo matches issues written by @mdo that contain the word "bootstrap" in the body.

Search by the assignee of an issue or pull request

The assignee qualifier finds issues and pull requests that are assigned to a certain user. You cannot search for issues and pull requests that have any assignee, however, you can search for issues and pull requests that have no assignee.

Qualifier Example
assignee:USERNAME assignee:vmg repo:libgit2/libgit2 matches issues and pull requests in libgit2's project libgit2 that are assigned to @vmg.

Search by a mentioned user within an issue or pull request

The mentions qualifier finds issues that mention a certain user.

Qualifier Example
mentions:USERNAME resque mentions:defunkt matches issues with the word "resque" that mention @defunkt.

Search by a commenter within an issue or pull request

The commenter qualifier finds issues that contain a comment from a certain user.

Qualifier Example
commenter:USERNAME github commenter:defunkt org:github matches issues in repositories owned by GitHub, that contain the word "github," and have a comment by @defunkt.

Search by a user that's involved within an issue or pull request

You can use the involves qualifier for finding issues that in some way involve a certain user. The involves qualifier is just a logical OR between the author, assignee, mentions and commenter qualifiers for the same user. In other words, this qualifier finds issues that were either created by a certain user, assigned to that user, mention that user, or were commented on by that user.

Qualifier Example
involves:USERNAME involves:defunkt involves:jlord matches issues either @defunkt or @jlord are involved in.
NOT bootstrap in:body involves:mdo matches issues @mdo is involved in that do not contain the word "bootstrap" in the body.

Search by a team that's mentioned within an issue or pull request

For organizations and teams you belong to, you can use the team qualifier to find issues or pull requests that @mention a certain team within that organization. Replace these sample names with your organization and team name to perform a search.

Qualifier Example
team:ORGNAME/TEAMNAME team:jekyll/owners matches issues where the @jekyll/owners team is mentioned.
team:myorg/ops is:open is:pr matches open pull requests where the @myorg/ops team is mentioned.

Search based on whether an issue or pull request is open or closed

You can filter issues and pull requests based on whether they're open or closed using the state or is qualifier.

Qualifier Example
state:open libraries state:open mentions:vmg matches open issues that mention @vmg with the word "libraries."
state:closed design state:closed in:body matches closed issues with the word "design" in the body.
is:open performance is:open is:issue matches open issues with the word "performance."
is:closed android is:closed matches closed issues and pull requests with the word "android."

Search by the labels on an issue

You can narrow your results by labels, using the label qualifier. Since issues can have multiple labels, you can list a separate qualifier for each issue.

Qualifier Example
label:LABEL cat label:bug matches issues with the word "cat" that are also labeled with "bug."
broken in:body -label:bug label:priority matches issues with the word "broken" in the body, that lack the label "bug", but do have the label "priority."
label:bug label:resolved matches issues with the labels "bug" and "resolved."

Search by milestone on an issue or pull request

The milestone qualifier finds issues or pull requests that are a part of a milestone within a repository.

Qualifier Example
milestone:MILESTONE milestone:"overhaul" matches issues that are in a milestone named "overhaul."
milestone:"bug fix" matches issues that are in a milestone named "bug fix."

Search by missing metadata on an issue or pull request

You can scope issues and pull requests to those missing certain metadata using the no qualifier. That metadata includes:

  • Labels
  • Milestones
  • Assignees
Qualifier Example
no:label priority no:label matches issues and pull requests with the word "priority" that also don't have any labels.
no:milestone sprint no:milestone type:issue matches issues not associated with a milestone containing the word "sprint."
no:assignee important no:assignee language:java type:issue matches issues not associated with an assignee, containing the word "important," and in Java repositories.

Search by the main language of a repository

You can choose to search for issues within repositories that match a certain language with the language qualifiers.

Qualifier Example
language:LANGUAGE language:ruby state:open matches open issues that are in Ruby repositories.

Search based on commit status

You can filter pull requests based on the status of the commits. This is especially useful if you are using the Status API or a CI service.

Qualifier Example
status:pending language:go status:pending matches pull requests opened into Go repositories where the status is pending.
status:success is:open status:success finally in:body matches open pull requests with the word "finally" in the body with a successful status.
status:failure created:2015-05-01..2015-05-30 status:failure matches pull requests opened on May 2015 with a failed status.

Search based on branch names

You can filter pull requests based on the branch they came from (the "head" branch) or the branch they are merging into (the "base" branch).

Qualifier Example
head:HEAD_BRANCH head:change is:closed is:unmerged matches pull requests opened from branch names containing the word "change" that are closed.
base:BASE_BRANCH base:gh-pages matches pull requests that are being merged into the gh-pages branch.

Search based on when an issue or pull request was created or last updated

You can filter issues based on times of creation, or when they were last updated. For issue creation, you can use the created qualifier; to find out when an issue was last updated, you'll want to use the updated qualifier.

Both take a date as a parameter. Date formatting must follow the ISO8601 standard, which is YYYY-MM-DD (year-month-day). You can also add optional time information THH:MM:SS+00:00 after the date, to search by the hour, minute, and second. That's T, followed by HH:MM:SS (hour-minutes-seconds), and a UTC offset (+00:00).

Dates support greater than, less than, and range qualifiers.

Qualifier Example
created:YYYY-MM-DD language:c# created:<2011-01-01 state:open matches open issues that were created before 2011 in repositories written in C#.
updated:YYYY-MM-DD weird in:body updated:>=2013-02-01 matches issues with the word "weird" in the body that were updated after February 2013.

Search based on whether a pull request is merged or unmerged

You can filter pull requests based on whether they're merged or unmerged using the is qualifier.

Qualifier Example
is:merged bugfix is:pr is:merged matches merged pull requests with the word "bugfix."
is:unmerged error is:unmerged matches closed issues and pull requests with the word "error."

Search based on when a pull request was merged

You can filter pull requests based on when they were merged, using the merged qualifier.

This qualifier takes a date as its parameter. Date formatting must follow the ISO8601 standard, which is YYYY-MM-DD (year-month-day). You can also add optional time information THH:MM:SS+00:00 after the date, to search by the hour, minute, and second. That's T, followed by HH:MM:SS (hour-minutes-seconds), and a UTC offset (+00:00).

Dates support greater than, less than, and range qualifiers.

Qualifier Example
merged:YYYY-MM-DD language:javascript merged:<2011-01-01 matches pull requests in JavaScript repositories that were merged before 2011.
fast in:title language:ruby merged:>=2014-05-01 matches pull requests in Ruby with the word "fast" in the title that were merged after May 2014.

Search based on when an issue or pull request was closed

You can filter issues and pull requests based on when they were closed, using the closed qualifier.

This qualifier takes a date as its parameter. Date formatting must follow the ISO8601 standard, which is YYYY-MM-DD (year-month-day). You can also add optional time information THH:MM:SS+00:00 after the date, to search by the hour, minute, and second. That's T, followed by HH:MM:SS (hour-minutes-seconds), and a UTC offset (+00:00).

Dates support greater than, less than, and range qualifiers.

Qualifier Example
closed:YYYY-MM-DD language:swift closed:>2014-06-11 matches issues and pull requests in Swift that were closed after June 11, 2014.
data in:body closed:<2012-10-01 matches issues and pull requests with the word "data" in the body that were closed before October 2012.

Search by the number of comments an issue or pull request has

You can use the comments qualifier along with greater than, less than, and range qualifiers to search by the number of comments.

Qualifier Example
comments:n state:closed comments:>100 matches closed issues with more than 100 comments.
comments:500..1000 matches issues with comments ranging from 500 to 1,000.

Search within a user's or organization's repositories

To grab a list of issues from all repositories owned by a certain user or organization, you can use the user or org qualifier. For getting a list of issues from a specific repository, you can use the repo qualifier.

Qualifier Example
user:USERNAME user:defunkt ubuntu matches issues with the word "ubuntu" from repositories owned by @defunkt.
org:ORGNAME org:github matches issues in repositories owned by the GitHub organization.
repo:USERNAME/REPOSITORY repo:mozilla/shumway created:<2012-03-01 matches issues from @mozilla's shumway project that were created before March 2012.

Search by the commit SHAs within a pull request

If you know the specific SHA hash of a commit, you can use it to search for pull requests that contain that SHA. The SHA syntax must be at least seven characters.

Qualifier Example
SHA e1109ab matches pull requests with a commit SHA that starts with e1109ab.
0eff326d6213c is:merged matches merged pull requests with a commit SHA that starts with 0eff326d6213c.

Further reading