Let’s begin with a definition of Haiku:

“A Japanese verse form most often composed, in English versions, of three unrhymed lines of five, seven, and five syllables. A haiku often features an image, or a pair of images, meant to depict the essence of a specific moment in time.”

Source: Poetry Foundation

How to write a poem using basic Haiku form:

A Haiku usually consists of 17 syllables.
The first and last lines have 5 syllables. 
and the middle line has 7 syllables.

Source: Books for Walls Project

An example from haiku master Matsuo Bashō:

No one travels
Along this way but I,
This autumn evening.

Source: Poetry Foundation