Dragon Ball GT actually is a direct sequel to Dragon Ball Z; it takes place several years after Dragon Ball Z ends. It was not based on a manga by Akira Toriyama. It was an original story created by the anime studio. As far as I know (I never finished watching it), it was completely compatible with the story of Dragon Ball Z.
Recently, Toriyama worked with Toei on the movies Battle of the Gods and Resurrection F, which as far as I know take place between the end of Dragon Ball Z's final battle with Kid Buu and its ending where Goku goes off to train Uub. These movies, like all the movies, are considered non-canon by fans, but Toriyama later adapted these movie stories into a new manga, Dragon Ball Super.
Since (a) GT was awful, and (b) Dragon Ball Super takes place after Dragon Ball Z but before GT and somewhat contradicts GT (e.g. Mai, Shu, and Emperor Pilaf are elderly in the first episode of Dragon Ball GT, while they're children in Dragon Ball Super after a bad wish on the Dragon Balls; also, there are characters like Beerus and Whis that I believe are nowhere to be found in GT, and new powers that are never seen or mentioned in GT, like the Super Saiyan God Form), most fans treat GT as non-canon. GT does actually follow the original Dragon Ball Z storyline, but it isn't compatible with Dragon Ball Super, and Dragon Ball Super is considered more authoritative since it was written by Toriyama himself.