A parser is a component of a compiler, which parses the source code of a computer programming language to create an internal representation. In more simpler terms a parser takes in input, a string from a source, and then breaks it down into smaller components that are easier for translation into another language.