From the text:
If he lifted his head he could see a glimpse of the distant forest. As the sun turned west there was a gleam of yellow upon its far roof, as if the light caught the last pale leaves. Soon he saw the orange ball of the sun sinking towards the level of his eyes. He went to the opening and there pale and faint was a thin new moon above the rim of Earth. At that very moment he heard a sharp crack behind him. There on the grey stone in the grass was an enormous thrush, nearly coal black, its pale yellow breast freckled dark spots. Crack! It had caught a snail and was knocking it on the stone. Crack! Crack!
Suddenly Bilbo understood. Forgetting all danger he stood on the ledge and hailed the dwarves, shouting and paying. Those that were nearest came tumbling over the rocks and as fast as they could along the ledge to him, wondering what on earth was the matter; the others shouted to be hauled up the ropes (except Bombur, of course: he was asleep).
Quickly Bilbo explained. They all fell silent: the hobbit standing by the grey stone, and the dwarves with wagging beards watching impatiently. The sun sank lower and lower, and their hopes fell. It sank into a belt of reddened cloud and disappeared. The dwarves groaned, but still Bilbo stood almost without moving. The little moon was dipping to the horizon. Evening was coming on. Then suddenly when their hope was lowest a red ray of the sun escaped like a finger through a rent in the cloud. A gleam of light came straight through the opening into the bay and fell on the smooth rock-face. The old thrush, who had been watching from a high perch with beady eyes and head cocked on one side, gave a sudden trill. There was a loud attack. A flake of rock split from the wall and fell. A hole appeared suddenly about three feet from the ground. Quickly, trembling lest the chance should fade, the dwarves rushed to the rock and pushed-in vain.
"The key! The key!" cried Bilbo. "Where is Thorin?"
Thorin hurried up.
"The key!" shouted Bilbo. "The key that went with the map! Try it now while there is still time!"
Then Thorin stepped up and drew the key on its chain from round his neck. He put it to the hole. It fitted and it turned! Snap! The gleam went out, the sun sank, the moon was gone, and evening sprang into the sky.
Now they all pushed together, and slowly a part of the rock-wall gave way. Long straight cracks appeared and widened. A door five feet high and three broad was out- lined, and slowly without a sound swung inwards. It seemed as if darkness flowed out like a vapour from the hole in the mountain-side, and deep darkness in which nothing could be seen lay before their eyes mouth leading in and down.