The Magic Labyrinth (1980) is a science fiction novel, the fourth in the series of Riverworld books by Philip José Farmer. The title is derived from lines in Sir Richard Francis Burton's poem The Kasîdah of Hâjî Abdû El-Yezdî:
Reason is Life's sole arbiter, the magic Laby'rinth's single clue:
Worlds lie above, beyond its ken; what crosses it can ne'er be true.
Originally intended to be the final book in the series, this book continues the chronicles of the adventures of Sir Richard Burton, Cyrano de Bergerac, Alice Liddell, Tom Mix, and Samuel Clemens through a bizarre afterlife in which every human is simultaneously resurrected along a single river valley covering an entire planet. Many questions about the creation and purpose of the Riverworld are answered, but several are left unanswered, prompting Farmer to write a fifth and final novel, Gods of Riverworld, in 1983.
Edgar L. Chapman wrote a 1984 biography of Farmer entitled The Magic Labyrinth of Philip José Farmer.