Gazebo is an independent structure with gable roof. Generally, it is a polygon with six or eight sides, whether it is round. May include the structure of the roof is open or may be good. Below are the pictures of gazebos to understand the difference between pergola and gazebo.
Pergola is a permanent structure or frame is on the side of an existing structure. Her columns supporting beams. Vertical on top of that this is then worked with some segments of the extra-ray partial shade. Have look some pictures of pergolas to understand that how pergolas look like.