Formal language theory plays, in computer science, a fundamental role that allows, among other things, the development of one of the cornerstones of information technology: programming languages. They define the mandatory grammatical rules that programmers need to follow to create the tools that enable humans to interact with machines. Despite its significance, formal language theory is often taken for granted, even by software developers, who regularly follow the rules of their programming domain. Unless the developer is creating its own programming language, data structure, or describing the formal background of an existing one, he will not need to dive deep into formal languages, grammar or automaton theory. Those who do need to develop their own rules will first have to understand the theory of formal languages, and the limitations they impose. This paper will do an introduction to the fundamentals of language theory, their classification, restrictions and representation. Once this ground rules are set, we will use a worldwide known data structure format such as the JavaScript Object Notation (JSON), to formally define its grammar rules and automaton. All of this formal background will allow us to transform theory into bits, by developing an algorithm that will analyze streams of texts, accepting or rejecting them as they comply or not with the predefined rules. Finally, we will analyze the outcomes of this implementation, its benefits, limitations, and alternatives that could have been followed.