Lenses couldn't be complete without one particularly good looking device. This is a little yet important piece of plastic or metal that attaches in front of the lens. This is called “the lens hood”, and honestly, each single lens should come with these pieces included instead of buying them separately.
Some brands such as Sigma know how important lens hoods are, and they include them with each lens, but brands such as Canon and Nikon only include them in their more expensive lenses.
What is the purposes of a lens hood?
Besides looking good, lens hoods have two major functions. The first is to protect the lens from light from the side, which reduces contrast and creates nasty flares in your images. Imagine it like a cap for sunny days, or even the instinctive act of putting your hand in
The second major purpose of using a lens hood is to give a certain amount of protection to the lens by having a front element that could receive a knock instead of something hitting the front element of your lens.
Be careful when buying generic lens hoods!
I remember the first time I bought a lens hood, it was for a 55-250mm and I wanted a petal
I recently bought a square hood for my camera, which is a generic version of the official (more expensive) lens hood from Fujifilm. But since it has the same shape, size and design, there is nothing wrong with it at all.