They are both Semitic languages along with Aramaic and many others.
“Semite” and “Aryan” belong to the same vocabulary, and have undergone the same perversions. Both date from the beginnings of modern philology in the 18th and 19th centuries, and from the momentous discovery that languages could be classified into cognate groups or families. In 1781, a German philologist called August Ludwig Schlozer suggested the term Semitic, from Noah’s son Shem, to designate the family of languages to which Assyrian, Hebrew, Aramaic, Arabic, and Ethiopic belong. Similarly the term Aryan, meaning “noble” and used by the ancient inhabitants of Persia and India to describe themselves, was adopted as the name of a group of related languages including Sanskrit, Old Persian, and some others. As far back as 1861 the great German philologist Max Muller pointed out that confusing the history of languages with the history of races would falsify everything. Nevertheless, race theorists, particularly those anxious to establish their own uniqueness and superiority, eagerly seized on this new vocabulary, and misappropriated it to their own use.
The defeat of Nazi Germany in 1945, and the discovery of the appalling crimes that had been committed in the name of racism, brought a change of attitude and, consequently, of usage. But not completely. Few nowadays outside the lunatic fringes would use the word “Aryan” as a racial designation, but the same taboo does not apply to the equally tainted and misleading use of the word “Semite.” Even otherwise respectable writers and journals sometimes permit themselves such pronouncements as that “the Jews and Arabs are both Semites.” If this statement has any meaning at all, it is that Hebrew and Arabic are both Semitic languages! “The Multiple Identities of the Middle East,” by Bernard Lewis.