List of all languages supported by github search


Is there a complete list of languages somewhere which are supported by GitHub search? I would also like to know what are the prefixes for the languages to be used when searching, e.g. - javascript -> js when searching.

Example: language:js someFunc().

Hello and welcome to the community @0xInfection.

The Linguist project is what we use to determine which language a file contains and it has a very exhaustive list of languages it recognizes. Each language can have a list of aliases that it recognizes and the languages.yml file is also where to find that information.

Let us know if you have any more questions!

1 Like

Hey @lee-dohm thanks for the great response, very much appreciated. Just a final question, whenever we search GitHub using the web search bar, there is a column at the left side displaying the top 10 languages where the search term has been found.

Is there a way I can grab that list from the GitHub API for a search?

1 Like

No, that information isn’t exposed directly through the GitHub API. You would have to search and then iterate through the list of individual results to collect that information.