The Trial of Ra was an ancient test established by Ra to test the capabilities of those who sought to enter his service, challengers being required to pass thirteen tests on thirteen worlds, each task requiring them to find the next gate address, along with a password required to activate the Stargate, before moonrise the day of their arrival. At the start of the test, the participants were infected with nanocytes that would be triggered if they attempted to depart the planet after their time frame ran out, the DHDs of each test having been altered to prevent anyone from simply dialling out to another planet.

The Trials were overseen by Bes, a mysterious being who it is implied had some connection to the Ancients, who had been defeated by Ra—who had somehow managed to attach his Ka, a piece of his soul, to the thirteenth planet in the Trial and forced to work as his servant. Under the terms of his servitude, Bes resided in the Barque of Heaven; a pleasant planet that awaited those taking the Trial after passing its last test and could travel to any of the worlds involved in the Trial, but could do nothing on his own.

SG-1 were forced to participate in the Trial when Mat, Ra's mate, learned of their role in Ra's death from Amaunet—although Sha're was apparently able to deceive Amaunet by concealing the full details of Ra's death from her, with the result that Amaunet believed that Ra had been killed only by Jack O'Neill, that the Abydonians had no part in his destruction, and that Daniel Jackson was a medical doctor. Mat set a bounty on SG-1's head, causing a Goa'uld mercenary to pose as a Tok'ra to provide SG-1 with the coordinates for the world where the Trials began, thus infecting them with the nanocytes and forcing them to participate in the test. Mat herself appeared on the twelfth planet of the Trial but was killed by SG-1 and her body vaporized by the unstable vortex of a Stargate to end her threat once and for all. On the last planet, SG-1 got rid of Ra's ka, enabling Bes to free and they returned safely to Earth. (SG1: "The Barque of Heaven")

Planet No. Test SG-1's Solution Notes
Gate No. 1 Stargate is on a cliff above a giant image of Ra's head, compared to Mt. Rushmore, with the address and password written on the face's beard Jack rappelled down the mountain and noted down the address and hieroglyphics for Daniel to translate later
Gate No. 2 The Trial participants must face four Jaffa opponents—servants of Ra who reside on that planet—in hand-to-hand combat with a weapon of their choice; in cases of group participation, other members of the team are prevented from aiding their comrades by a forcefield Sam, Teal’c and Jack defeated their opponents; Daniel was able to convince the planet's leader that Ra was dead, prompting him to spare Daniel and provide them with the address and password The Jaffa leader initially believed Daniel to be a young Goa'uld leading the others; asked Daniel to pass a message on to his family on Dashani before SG-1's departure
Gate No. 3 Stargate and DHD located on two thin platforms on an otherwise flooded planet; the password was carved underwater in a temple, while the address could only be accessed by solving a puzzle-code involving the symbol of the Eye of Ra Daniel translated the password and he and Jack subsequently found the address SG-1 lost the FRED they had been using to transport their supplies; Teal'c and Sam managed to salvage most of their belongings
Gate No. 4 Password and address were located in a secret door hidden in a sphinx, only accessible via a riddle carved on the sphinx The riddle opened a compartment in the back of the sphinx' head, where a Goa'uld would enter a host SG-1 faced various Goa'uld who had been stranded there in the past; one attempted to take Daniel as a host upon their arrival, while another followed them through the Stargate after they departed
Gate No. 5 Several spheres encoded with the names of various other members of the Goa'uld hierarchy, requiring participants to correctly identify Ra's allies from the list; a neural transmitter broadcasts a frequency that distracts and disorientates the participants. After being distracted by the signals sent by an unidentified transmitter, as well as the fruit of the planet, SG-1 cracked the sphere mystery with Teal'c's knowledge of Ra's history The Goa'uld that followed them through the Stargate from the previous world was disintegrated by the nanocytes
Gate No. 6 Participants must stand before an altar and confide a precious memory to it, showing their honesty and worth Sam recalled her time spent learning about science with her mother; Jack remembered how his life changed when he first held Charlie; Daniel reflected on a night he had spent sitting silently with Sha're; Teal’c revealed that he had fathered four other children apart from Rya'c, but all of them were dead Before they reached the altar, the rest of the team were briefly rendered ill by the plants they had consumed on the previous planet, but Jack was able to cure them with some flowers that he had eaten, realising that they were responsible for his immunity as the only thing he had eaten that the others had not
Gate No. 7 A row of posts near the Stargate reveal the password and address, but a fog on the planet prevents sound from being audible SG-1 used their explosives to clear the fog from around the DHD long enough for them to use the password and dial the address
Gate No. 8 A statue in a temple designed in homage to Thoth—also known as Djehuti—which would grant the trial participant knowledge of the Books of Djehuti—including knowledge of Ra's true history and language, along with the password and address for the Stargate—via an implant; when the Trial concludes, the participant must choose whether to retain knowledge of Ra's history or his language Teal'c took the knowledge from the Book in the belief that it might be dangerous for Daniel to accept the knowledge; his symbiote was rendered immobile until the implant was removed
Gate No. 9 The address and password were written on the DHD, while the planet itself was Ra's personal armory protected from outside access by a forcefield; the test determines whether people can focus on their mission when faced with a wealth of technological knowledge SG-1 resolved to continue their search Stargate Command and the Tok'ra are able to contact SG-1 via a communication device left in the warehouse by a Tok'ra agent who took the trial before; the Tok'ra offer to take SG-1 offworld and extract the nanocytes, but SG-1 resolve to continue the Trials because there is no other way to remove the Book of Djehuti without killing Teal'c
Gate No. 10 The team are attacked and rendered unconscious by native creatures, and must make it back to the Stargate before time runs out; the creatures will then reveal the address and password in the language of the Book of Djehuti Teal'c and Sam are captured and rescued by Jack and Daniel Teal'c apologises for injuries he and Jack caused to one of the creatures while escaping
Gate No. 11 The team must pass war games against virtually-generated opponents to gain access to a temple where the keys to the password can be found One of the keys had been lost when a prior participant in the Trial was crushed before he could use it; SG-1 located it using Daniel's archaeological skills Daniel listened to a recording left by the previous trial participant before they departed
Gate No. 12 Using a ring transporter, the team travelled to a temple where the address and password are carved on various artefacts in a mathematical code Bes provided SG-1 with the password as the Trial had been unfairly tampered with Mat confronted SG-1 at this point, but they escaped; Bes assisted them in finding the address as they had been unfairly disadvantaged
Gate No. 13 After crossing a gorge filled with sharp rocks and occasional stepping-stones, the participants must use all twelve passwords in front of twelve pedestals Having been taken to the Barque of Heaven, Teal’c requested that he be allowed to keep the record of Ra's history, confident that Daniel would be able to translate the language in future. SG-1 were confronted by a fragment of Ra's soul that he had left on this planet to "guard" Bes and the Barque of Heaven; they were apparently able to exorcise the soul with an old ritual