Stick insects (also called phasmids, walking sticks, stick-bugs, or ghost insects) are insects in the order Phasmatodea (or Phasmida).

The whole order is camouflaged as either sticks or leaves. Leaf insects are generally the family Phylliidae. They are found in south and southeast Asia to New Zealand. 

Over 3,000 species have been described.

The name Phasmatodea comes from the Ancient Greek phasma, meaning an apparition or phantom.

Life habit 
The order has a worldwide distribution, but most species are found in the tropics. These tropic species vary from stick-like species to those resembling bark, leaves and even moss or lichen. The stick insect can sometimes reach over 13 inches (33 cm) long. The longest is Chan's megastick.

A few species, such as Carausius morosus, are even able to change their pigmentation to match their surroundings. Many species are wingless, or have reduced wings.

Phasmids are herbivorous, feeding mostly on the leaves of trees and shrubs. Their eggs are usually camouflaged, look like plant seeds, and may remain dormant for a full season or more before hatching. The nymphs are born already closely resembling the adults.

Behaviour
Stick insects make rhythmic, repetitive side-to-side movements. This is like vegetation moving in the wind. This is used to stick bug people.

Also, the swaying movements may help the insects see objects against the background. Rocking movements by these sedentary (sitting) insects may replace flying or running as way to define objects in the visual field.

Some species of phasmid are able to produce a defensive spray when threatened. The spray contains pungent-smelling volatile molecules which the insect gets from its food plant. The spray from one species, Megacrania nigrosulfurea, is even used as a treatment for skin infections by a tribe in Papua New Guinea by virtue of its antibacterial constituents.

Mating involves long pairings. A record among insects, the Indian stick insect Necroscia sparaxes was seen coupled for 79 days at a time. It is not uncommon for this species to assume the mating posture for days or weeks on end, and among some species (Diapheromera veliei Walsh and D. Covilleae), pairing has been seen to last three to 136 hours in captivity.
Explanations for this behaviour range from males guarding their mates against other males, to the view that the pairings are a defensive alliance against predators.

Defences 
They are unusual in that the whole order is camouflaged. They are all mimics of their natural background. Some species (such as O. macklotti and Palophus centaurus) are covered in mossy or lichenous outgrowths that supplement their disguise. Some species can change color as their surroundings shift (B. scabrinota, T. californica).  Many species have a rocking motion, where the body sways from side to side, like leaves or twigs swaying in the breeze. The nocturnal feeding habits of adults also helps them to hide from predators.

Secondary defences 
Once found, they make use of secondary defences. 
They may play dead. That is called "thanatosis". 
They often use "startle displays" for defence if discovered and threatened. As a predator approaches, they flash bright colors and make a loud noise. Some species, drop to the undergrowth to escape, and open their wings momentarily during free fall to show bright colors that disappear when the insect lands.  Others will maintain their display for up to 20 minutes, hoping to frighten the predator and convey the appearance of a larger size.  Some accompany the visual display with noise made by rubbing together parts of the wings or antennae. Some species, such as the young nymphs of E. tiaratum, have been observed to curl the abdomen upwards over the body and head to resemble ants or scorpions in an act of mimicry, another defence mechanism by which the insects avoid becoming prey.
When threatened, some phasmids have femoral spines on the front legs (O. martini, Eurycantha calcarata, Eurycantha horrida, D. veiliei, D. covilleae). They curl the abdomen upward and repeatedly swinging the legs together, grasping at the threat.  If the menace is caught, the spines can draw blood and inflict considerable pain.
Noxious chemicals may be used. A number of species have glands at the front which release chemical compounds. These chemicals may give off unpleasant smells or cause a stinging, burning sensation in the eyes and mouth of a predator.  Recent research suggests they manufacture their own chemical defense substances.  Some species employ a shorter-range defensive secretion, where individuals bleed reflexively through the joints of their legs and the seams of the exoskeleton when bothered. The blood contains distasteful additives. Stick insects, like their distant relation the grasshopper, can also discharge the contents of their stomachs through vomiting when harassed, a fluid considered uneatable by some predators.

Distribution 
Their natural camouflage can make them extremely difficult to spot. Phasmatodea can be found all over the world in warmer zones, especially the tropics and subtropics. The greatest diversity is found in Southeast Asia and South America, followed by Australia. Phasmids also have a considerable presence in the continental United States, mainly in the Southeast.

Taxonomy 
The main groups are:
Phasmatidae: the stick insects (there are some other families)
Phylliidae: the leaf insects

References