(CNN)On a beach vacation, a venomous sea slug probably isn't high on your must-see list.
That's exactly what San Antonio resident Erick Yanta came across on his trip to Mustang Island, an 18-mile-wide stretch of land in the Gulf of Mexico near Corpus Christi, Texas.
While strolling along the beach, Yanta and his wife, Anna, spotted a tiny blue and white creature no longer than an inch clinging to a rock. He scooped it up to take a closer look and filmed it before carefully placing it back into the water.
Yanta didn't know it at the time, but they had encountered the venomous Glaucus atlanticus, also known as the "blue dragon."
"We've seen plenty of jellyfish like the Portuguese man-of-war, but never this animal," Yanta said. The Portuguese man-of-war is a siphonophore, a species closely related to jellyfish, according to the National Ocean Service.
As soon as he captured the video, Yanta hopped onto Reddit so users could help him identify the animal.
They adapt to avoid predators
The blue dragon normally lives on the surface of the open ocean, said David Hicks, professor and director of the School of Earth, Environmental, and Marine Sciences at the University of Texas Rio Grande Valley in Edinburg.
The slugs have a bright blue underbelly and a softer silvery tone on their back, he said. Blue dragons float on their back so the blue on their underside can blend in with the water while the gray blends in with the sea surface, Hicks said.
This is called countershading, an evolutionary trait that helps animals avoid predators, he said.
The sea slugs can be found at nearly any beach in the tropical and subtropical latitudes, but their small size means most beachgoers don't see them, he said.
"They are also soft-bodied, so they are often broken apart by the time they get through the surf zone and deposited on the shore," Hicks said.
A venomous sting
Despite their small size, blue dragons pack quite a punch with their sting.
The animal eats creatures like the venomous Portuguese man-of-war and stores its prey's stinging cells, called cnidocytes, in sacs, Hicks said. Blue dragons will use the cells to protect them from predators, and humans sometimes get caught in the crossfire.
The pain of being stung feels similar to a man-of-war sting, which can be quite painful and, in rare instances, life-threatening, Hicks said. Symptoms following a sting can include nausea and vomiting, according to American Oceans.
If you are stung by a blue dragon, it is best to go to a hospital for treatment, according to Ocean Info.
Yanta did not know that the blue dragon he found was venomous and later laughed when he realized what he had held. He said that knowing ahead of time wouldn't have made a difference though.
"I would've done the same thing," Yanta said. "I would've still scooped it up, filmed it and put it back in the water."