Nowadays, we know that many languages are "related," because they stem from a common ancestor. But when did people begin to realize this? Did people always understand that some languages had similar structure, syntax, and similar sounding words - whereas others seemed to have completely alien features?
For instance, did ancient Romans understand that Latin had similarities to Gaulish, Greek, and Persian - and that it was drastically different from Egyptian, Aquitanian, and Etruscan?
People knew from early on that some languages sound similar: for example, Jewish bible interpreters in Arabic-speaking places used their knowledge of Arabic to help them parse difficult Hebrew words. But they also try to do that with Greek sometimes, because they're basically looking for words that sound alike, not for words that are actually related.
Similarly, in the middle ages, Europeans obviously knew that most of their languages sound alike and that they sound like Latin. But their conclusion was that all the different languages existed and they developed Latin to be a common language between all of them.
Sir William Jones, in the 18th century, was the first person to actually figure out that Indo-European languages are all related and have a shared ancestor.