The Golden Path ("Secher Nbiw" in the ancient Egyptian language) was an expansive prescient interpretation that was only visible to the Kwisatz Haderach. It foretold the fluid events of the future, both great and small. More profoundly, however, it revealed an optimum path through the countless threads of cause and effect that were encountered by the human race.
In essence, the Golden Path entailed a restriction in spice production alongside spice stockpiling and the terraforming of Arrakis. The terraforming killed off all the worms, and the lack of spice restricted space travel. Eventually, after centuries of careful and deliberate oppression, Leto II was destined to die and release new sandtrout to begin a new worm-spice cycle. Subsequently, this caused the expansion of human domains far beyond the boundaries of the known universe, guaranteeing the preservation of humanity in the long term by inducing a massive expansion and diversification of human population, territory and culture.
Dangers for Humanity
Through prescience, Paul Atreides and Leto II foresaw that humanity would end if it stagnated and remained confined within the known universe and rigid class structure of the Imperium. Though the Imperium's population was many trillions, Leto II's rule proved that humanity was still confined within a space that could be controlled by a single interest. Although rarely addressed directly, it was often suggested that this lack of exploration and growth left humanity vulnerable to being endangered by a single threat, which would lead to the eventual destruction of humanity. The conflict between humanity's stated desire for peace and their actual need for volatility was the strong central theme of the entire Dune series, explored in every book after the first. God Emperor Leto II's stated goal was to "teach humanity a lesson that they will remember in their bones": that sheltered safety was tantamount to utter death, however long it would be delayed.
Though the Bene Gesserit had long anticipated the existence of The Golden Path, the term was first vocalized by Paul Atreides after the defeat of House Atreides on Arrakis. However, its inherent dilemmas were only apparent to him after he ingested the Water of Life. Even with his considerable powers Paul struggled to determine the best path through the maze of decisions presented to him. This was possibly due to the fact that he was not the ultimate Kwisatz Haderach, having been born a generation sooner than the Bene Gesserit had planned. It was more likely, however, that Paul's difficulty with maintaining a clear oracular vision was because of his own emotions. Much like his father, Paul was forever tempted by a simpler life, far away from the intrigues and dangers of prescience, Imperial politics, and war. He was also continually haunted by the death of his father, and the manner in which his House was betrayed by so many. However it could also be that Paul was constricted by his own prophecy; he could not walk the Golden Path because he knew his son was the one destined to do so, not he.
After Paul's apparent death in the deserts of Arrakis, his son Leto - also technically a (and perhaps more accurately the) Kwisatz Haderach - began to see The Golden Path, but unlike his father he chose to begin it (or perhaps he was always destined to do it). Leto's ability to see into the threads of causality allowed him to craft a future in which he became a human-sandworm hybrid, and thus the long-lived God-Emperor.
In this form he guided humanity with an iron fist for three and a half thousand years, an intricately crafted design leading to the final stroke where he would ultimately use his own death to take The Golden Path even further.
At first The Golden Path appeared to culminate in the ascent of House Atreides, jihad, the spread of Fremen customs, and the terraforming of Arrakis. However, Leto extended it to incorporate an expansion in the diversity and safety of the human race, via The Scattering, as well as preventing Mankind from being trapped by prophecy both by removing the ability to see into the future from humanity through spice deprivation, and by breeding a human strain invisible to prophets through the traits inherited from Siona, who used this ability to successfully slay the prescient Leto II.
Despite the death of the two men who had enforced The Golden Path, its effects and ramifications were obviously still felt beyond the return of the Honored Matres and their eventual merger with the Bene Gesserit. Indeed, The Golden Path saw humanity explode across the universe, taking with it what it had known, and returning with it knowledge and technology never before encountered in the Old Imperium. Moreover, The Golden Path saw humanity's physical attributes change, so that their reflexes, nervous responses and physical movements were significantly faster than during the time of the Faufreluches.
Future Time Strands
The "great enemy" that threatens humanity in Leto's visions is not discussed in great detail. Frank Herbert makes vague references to visions of future-time strands seen by Paul and Leto II, wherein humans are fleeing machines, possibly of Ixian manufacture, designed solely to seek out and destroy human life and equipped with prescient abilities allowing them to hunt down all of humanity without fail. Another theory is the return of ancient artificial intelligent machines which had been thought to be wiped-out during the Great Revolt. A future containing that fate would be the type of future that would compel a prescient Leto II to take humanity down his Golden Path, i.e., enforced tranquility, and accept his own fate of returning to the sand. Another possibility is that the great enemy was a superior alien race, originating in another galaxy, or even dimension. The return of machines would be reminiscent of the Butlerian Jihad, the quest to terminate thinking machines that were bent on destroying humanity. This would imply that humanity was undergoing a cycle of failures, continuously repeating history and their mistakes. Perhaps then the Golden Path was a way of breaking the cycle, by fixing humanity's mistakes by fixing the errors in humanity leading to the mistakes.
Some might say, however, that the enforced tranquility of the Tyrant's rule was building up pressure for the Golden Path, which was implemented by the Scattering. The Tyrant's rule certainly forced technological evolution, because anybody interested in escaping or ending the Tyrant's power first needed ways to nullify his prescience, which was eventually accomplished by no-globes and no-ships in a way that paralleled the Tyrant's own breeding for humans that were biologically invisible to prescient vision.