The quest guard is an adventure map structure in Heroes III and Heroes IV. Like the border guard, it blocks players from passing through an area until it has been opened, but it doesn't require a keymaster's tent to open. Instead, it will give heroes approaching it a quest, and once the quest has been completed and the hero has returned to the tower, the path will be opened.
Some quest guards might ask the hero to bring a specific artifact, or bring them a certain amount of resources, or kill a specific creature or hero, and some quest guards can only be opened by a specific hero.
The quest gate is a mixture of a quest guard and a border gate, appearing in Heroes IV. Like the quest guard, it will allow heroes to pass through once a specific condition is true, but like the border gate, it won't allow anyone through once it has been opened - only heroes for which the specific condition is true, are allowed to pass.
The quest gate often appears in campaigns, with the condition that only the main hero is allowed through, making sure that no secondary heroes are allowed to defeat the villain for them. One example is The Rightful Heir, where only Lysander can pass through for his final fight with Sir Worton - he can't bring any heroes or creatures with him.