By definition, the connotation of a word or phrase, or an element of a piece of literature is based upon what is implied. It is not concrete in nature, but abstract. Denotation is specific…concrete in nature. For example, the connotation regarding the idea of the passage of time might well be represented by the journey of an old man—like a metaphor. However, denotation would explain the passing of time in terms of the completion of seconds, minutes, hours, days, etc.
In other words connotation refers to...
…suggestions and associations which surround a word...
On the other hand, denotation refers to...
...as opposed to [a word's] bare, literal meaning.
In Kafka's The Metamorphosis, connotation and denotation are used masterfully by the author.
There has long been debate over what actually takes place in the story of Gregor Samsa over whether he actually becomes a giant insect (denotation) or if he simply feels like a revolting creature that has become isolated from his grasping, greedy and lazy family members (connotation).
Whereas denotation speaks to what actually takes place, connotation leaves room for interpretation. Refer to the attack against Gregor in Chapter 2 of the story.
[Gregor’s father] had filled his pockets from the fruit bowl on the credenza, and now, without aiming precisely, threw apple after apple… One direct hit...penetrated Gregor’s back; Gregor wanted to drag himself a little further, as if the unexpected and unbelievable pain would go way with a change of position, and yet he felt like he was nailed down and stretched out…
In Chapter 3, the pain of the "apple" is mentioned again:
It was true that [Gregor's] whole body hurt, but it seemed to him as if the pains gradually grew slighter and slighter and that they would eventually go away completely. He now hardly felt the rotten apply in his back and the inflammation around it…
There are several things to study here with regard to "connotation" and "denotation."
Denotation would refer to actual apples being thrown into Gregor's back in Chapter 2. A connotation might suggest that the apples were symbolic of insults hurled at Gregor from which he could not emotionally recover.
When Gregor reflects in Chapter 3 on the fading pain from the apple still in his back, one might denote that Gregor is healing or recovering from the injury. A connotation would be that the emotional injury is fading, or that Gregor's depression over his family's rejection is destroying him within.
Connotation and denotation are similar to what is figurative as opposed to the literal. Consider the following:
Dirt streaks stretched all along the walls; here and there lay balls of dust and filth.
Denotation reflects that this is literal: there is dirt everywhere. Connotation might imply that there is no actual dirt, but that the atmosphere instead is one of unkindness, and emotional desolation and neglect.
Denotation describes the literal: facts and what is actually there…"the bare literal meaning." Connotations reflect emotional responses, metaphors, etc. Where there is room for interpretation, connotation will take place. Where there is no room for interpretation, denotation is present.