This is the 19th printing in the Canto series of a classic. Written in 1940, it was extended with a foreword by C.P. Snow since the 1967 edition. The chemist and novelist Snow gives a human biography of his friend Hardy, and Hardy himself contemplates at the age of 62 on his waning mathematical abilities and on the usefulness of dull elementary mathematics as opposed to the harmless beauty of pure mathematics, which he considered to be a body of creative art presumably without any application.
In 1940, at the age of 62, and at the verge of WW II, G.H. Hardy wrote down his apology, in an attempt to justify his life as a mathematician: is the work that a man does during his life worth doing, and why does he do it?
The second question has two possible answers: either he does it because he is good at it or because he is not good at anything and it just so happened. The first reason applied to himself: There is no doubt that I was right to be a mathematician, if the criterion is to be what is commonly called success. Note the past tense. Hardy is convinced that mathematics, more than any other art or science is a young man's game. All great mathematicians achieved their main results at a young age, and they either died young or did something else later in life. So he is implicitly regretting his waning mathematical skill.
The other question about why mathematics is worth doing takes more pages. He claims that mathematics is an unprofitable, perfectly harmless and innocent occupation. With unprofitable he means not directly of use like medicine or physiology is, and harmless refers to not applicable in e.g. warfare.
As for the usefulness, it should be clear that he refers to what he calls 'real' mathematics, i.e. what we should call pure mathematics, which is quite different from the repulsively ugly and intolerably dull school mathematics which indeed have applications in daily life and are applied by e.g. engineers. If it is useless, then it is harmless. If it can not be used, then it can not be used for good purposes, but neither can it be misused for evil ones.
Pure mathematics are universal, deep and beautiful. A chess problem is mathematics but unimportant and not serious. Moreover it is general and of all times: Babylonian and Assyrian civilisation have perished; Hammurabi, Sargon, and Nebuchadnezzar are empty names; yet Babylonian mathematics are still interesting. Pythagoras, Newton and Einstein are people who influenced science considerably. As examples of serious mathematics he gives Euclid's proof of the infinity of prime numbers and the proof of Pythagoras on the irrationality of √2.
A proof gets some aesthetics from unexpected twists, which is not found in a proof by enumeration or using standard techniques. The deeper the result, the less straightforward the proof will probably be.
Hardy also contemplates the difference between pure and applied mathematics. For example the applied geometry of our surroundings will change when a massive gravitational object will be brought into the room. However, the theorems of pure geometry that have been proved in that same room do not change. In a sense the mathematician is in more direct contact with reality than e.g. a physicist. For example a chair can be a collection of whirling electrons or anything else, depending on the model used to describe the physics, but a mathematical object is exactly what it is, no interpretation possible. There are many possible models for the physical world, yet 317 is a prime not because we think it is, [...] but because it is so.
The foreword by C.P. Snow takes about one third of the booklet. It has been added since the 1967 edition of the Apology. Snow is a chemist and novelist. When Hardy returned from Oxford to Cambridge in 1931. Snow was invited by Hardy because he wanted to speak about cricket, a passion they both shared. They became good friends thereafter. The foreword is basically a short, yet very human biography of Hardy, not about his mathematical achievements but rather about his opinions and his character as a human being.
Hardy's text is now more than 70 years old, and it is clearly a plea for pure mathematics, but obviously Hardy is also formulating a justification of his own life. Some of his viewpoints are controversial, and some arguments may no longer hold (his beloved field was number theory which became a very important element in decoding the German Enigma machine during WW II, although he may have considered that as dull and applied, and not of the pure and creative sort). Yet his ideas are so clearly formulated, that it is still advisable for any mathematician to read it, discuss it with colleagues, and think about an apology for his or her own life as a mathematician. So we are very lucky that the booklet is still available in print.
The apology by Hardy is publically available courtesy of the University of Alberta Mathematical Science Society. The foreword by Snow is not.