A dragon was a type of winged serpent-like reptilian animal. Such animals were known to live on Berengaria VII and Maravel. As the result of extra-terrestrial contact, Earth mythology also featured dragons.
A Vulcan survey team to Berengaria VII made note of a species as one of flying reptiles, over two hundred meters in length, that breathed fire. A century later, Spock had seen a dragon when he visited the planet. (ENT: "Bound"; TOS: "This Side of Paradise")
Also in 2269, Hikaru Sulu and Leonard McCoy were chased by a two-headed, fire-breathing mechanical dragon on the Shore Leave Planet when the planet's master computer was attempting to "turn off" the Enterprise landing party. After the master computer agreed to cease its pursuit, McCoy and Sulu were seen on the master computer's viewscreen, enjoying a picnic with the dragon, Alice, and the White Rabbit. (TAS: "Once Upon a Planet")
In Earth culture
On Earth, dragons were more commonly known as supernatural monsters or deities in the myths of the Native Americans, Europeans and Chinese. In 2270, it was discovered that the basis of these myths was Kukulkan, an immensely old alien being who had visited all the nations on Earth in the distant past. (TAS: "How Sharper Than a Serpent's Tooth")
An ancient Greek myth told of a dragon that fell in battle, whereupon its teeth took root in the ground and sprang back as warriors to continue the fight. In 2376, Chakotay compared the hundreds of bio-pods containing the last survivors of the Vaadwaur race to dragon's teeth. (VOY: "Dragon's Teeth")
In medieval times, it was noted on maps where the explored regions ended, that beyond this place there be dragons. If a ship were to sail too far out into the ocean, crews might threatened to hang their captain from the yard arm if he refused to turn back. (TNG: "Where Silence Has Lease")