I know that there are no standard definitions for pure and applied mathematics however I would like to know who first considered them as two separate entities, I have seen people mention it was around the late 18th early 19th century but I can't find any conclusive evidence to support this.
The earliest evidence we have of the distinction being made explicitly is in Plato's Republic, where he criticizes the manner in which geometers express themselves given the exalted (according to him) object of their study:
"They speak, I suppose, very laughably and perforce, for they mention squaring, applying, and adding, and state all their claims as if they are engaged in action and fashioning all their proofs for the sake of action; but the fact is, I presume, that the whole science is pursued for the sake of knowledge... That the knowledge pursued is of the eternally existent but not of what comes to be at any particular time and perishes."
Plato himself, of course, also encouraged geometers to "save the phenomena" of the heavens by reconstructing their apparent disorder from orderly circular motions. In answering his call Eudoxus created mathematical astronomy where rotating nested spheres were featured. But because epigones have to be holier than their authority Plato's successors at the Academy, notably his nephew Speusippus who took over after him, extended his disapproval from the manner of expression to entire parts of mathematics that used "mechanical" methods, such as rotations that produced curves Eudoxus and Archytas used to duplicate the cube. Proclus describes a debate over "problems" vs "theorems" in post-Plato's Academy, where Menaechmus (the inventor of conic sections) opposed Speusippus by defending geometers' methods, see Menaechmus versus the Platonists by Bowen. In any case, by the time of Plutarch the distinction between mathematics of the intelligible (pure) and mathematics of the sensible (applied) already solidified. Plutarch writes in De vita Marcelli:
"For Eudoxus and Archytas, who embellished geometry with subtlety, initiated this highly regarded and famous art of mechanics, by supporting problems not easily solved with proof through discursive argument and diagram, by means of sensible and practical illustrations: for example, both reduced the problem concerning two mean proportionals, an element in many geometrical figures, to mechanical constructions in adapting certain mean proportionals from curved lines and sections.
But, since Plato was displeased and opposed them on the ground that they destroyed and corrupted the good of geometry, which relapses from incorporeal, intelligible objects to sensibles and, moreover, uses bodies needing much vulgar manual labour, mechanics was thus distinguished as falling outside of geometry, and, since it was for a long time disregarded by philosophy, it has become one of the military arts."
Academy's influence, with its condemnation of applied as corrupted, was felt in antiquity despite the pushback from prominent mathematicians. Euclid deliberately avoids motion or any "mechanics" in the Elements, many of his proofs are more convoluted because he replaces use of congruence by constructing various auxiliary triangles. Hellenistic geometers, especially Archimedes and Apollonius, made a point of mixing mechanics and geometry, including the use of mechanical curves like spirals and helices. Apollonius even suggested some alternative proofs for Elements to relax Euclid's purity, see Acerbi's Two Approaches to Foundations in Greek Mathematics: Apollonius and Geminus. But even Archimedes shaped his work on the law of the lever and floating bodies into the Euclidean mold, and described his mechanical method for computing areas and volumes only in private letters, reproving them by Euclid-approved double reductio ("method of exhaustion") in "official" works. That the Academic attitude survives to modern times can be seen from Hardy's Mathematician's Apology, where he exalts pure mathematics over applied on the familiar platonist grounds:
"317 is a prime, not because we think so, or because our minds are shaped in one way rather than another, but because it is, because mathematical reality is built that way. [...] A mathematician, like a painter or a poet, is a maker of patterns. If his patterns are more permanent than theirs, it is because they are made with ideas. [...] The mathematician’s patterns, like the painter’s or the poet’s must be beautiful; the ideas like the colours or the words, must fit together in a harmonious way. Beauty is the first test: there is no permanent place in the world for ugly mathematics. [...] Pure mathematics is on the whole distinctly more useful than applied. [...] I have never done anything 'useful'. No discovery of mine has made, or is likely to make, directly or indirectly, for good or ill, the least difference to the amenity of the world."
It is often pointed out that, ironically, Hardy's number theoretic work was put to the amenity of the world very directly soon after his death, in public key cryptography.
There is, of course a wikipedia entry on pure mathematics and a ref to a Sadleirian Professor of Pure Mathematics since 1710. Arguably, Plato may be the first to have emphasized the distinction number theory vs. computation ('arithmetic' vs. 'logistike')
It is more or less obvious that pure maths somehow developed from 'impure' maths. The ultimate motives for the sexagesimal system adopted by Old Babylonian mathematics are its advantages for computation (especially fractions). But clay tablets as YBC 7289 or Plimpton 322 already present results which appear to be of purely academic interest. The name geo-metry adopted in Greece a thousand years later betrays also application as origin. The so called pythagoreans appear to be the first interested in numbers as such. Disregarding the current debate about their nonexistence (Burkert, Zhmud) they are a generation or two before Plato. Greek astronomy originally was mostly 'calendrical' or observational but presocratics thinkers already proposed models which came to be refined. Later Ptolemy's purely geometrical model generated realiable data, while the nested spheres adopted by peripatetics were used as an explanatory physical device.
Newton famously said in the preface of his Principles that geometry is really mechanics. And geometry as a natural science survived until the advent of non-Euclidean geometries which decisively marked a branching of pure and applied forms of mathematics.
As Mauro Allegranza wrote in his comments the distinction can be traced to ancient Greece, more precisely to Hellenistic times, though it was not formalized. Subjects like music, mechanics, optics and astronomy were considered parts of mathematics. At the same time there was "physics".
The distinction was that in "mathematics" they had axioms and theorems while in physics they started with "phenomena" (observations).
Euclid wrote books on Optics and on harmony treating them as mathematical subjects. First Greek books on astronomy were pure mathematical, with no much regard to observations. Notice that Ptolemy's book (which is known now as Almagest) was called Mathematical Syntaxis, and Newton's book Principia Mathematica, though certainly observations played a fundamental role in both.
The distinction was probably formalized in 19th century when the first mathematical journals appeared:
Journal fur die reine und angewandte Mathematik, and Journal de mathematiques pures et appliquee.