What is the difference between a metaphor and a simile?
A simile compares two things using like or as. A metaphor states that one thing is another.
Her argument was like a hammer. (simile) Her argument was a hammer. (metaphor)
The distinction is not merely mechanical. A simile keeps a small distance — it acknowledges that the comparison is a comparison. A metaphor collapses that distance and asserts the identity outright, which is why metaphors generally land harder.
Both belong to a wider family of figurative language:
Analogy explains something unfamiliar by mapping it onto something familiar, usually at greater length and with the mechanism spelled out. A computer's memory works like a desk: the desktop holds what you are using now, the drawers hold what you might need later.
Personification gives human qualities to something that is not human. The wind complained all night.
Hyperbole is deliberate exaggeration not meant literally. I've told you a thousand times.
Idiom is a fixed phrase whose meaning cannot be worked out from the words. Kick the bucket.
A dead metaphor is one used so often that nobody notices the image any more — the leg of a table, running out of time, the heart of the matter. These are not errors; they are simply how language accumulates.
A mixed metaphor combines two incompatible images and usually reads as a mistake. We'll burn that bridge when we come to it is a well-known example.
The practical test for a metaphor: if the sentence would be false read literally, and the writer knows it, it is figurative.
A note on literally: it is often used to introduce a metaphor, which is the usage that irritates people precisely because it claims the opposite of what figurative language does. If a comparison is figurative, it does not need literally in front of it.