Sword and planet is a subgenre of science fantasy that features rousing adventure stories set on other planets, and usually featuring Earthmen as protagonists. The name derives from the heroes of the genre engaging their adversaries in hand-to-hand combat primarily with simple melée weapons such as swords, even in a setting that often has advanced technology. Although there are works that herald the genre, such as Percy Greg's Across the Zodiac (1880) and Edwin Lester Arnold's Lieut. Gullivar Jones: His Vacation (1905; published in the US in 1964 as Gulliver of Mars), the prototype for the genre is A Princess of Mars by Edgar Rice Burroughs originally serialized by All-Story in 1912 as "Under the Moons of Mars".
The genre predates the mainstream popularity of science fiction proper, and does not necessarily feature any scientific rigor, being instead romantic tales of high adventure. For example, little thought is given to explaining why the environment of the alien planet is compatible with life from Earth, just that it does in order to allow the hero to move about and interact with the natives. Native technology will often break the known laws of physics.
The genre tag "Sword and planet" is constructed to mimic the terms sword and sorcery and sword and sandal. The phrase appears to have first been coined in the 1960s by Donald A. Wollheim, editor of Ace Books, and later of DAW Books at a time when the genre was undergoing a revival. Both Ace Books and DAW Books were instrumental in bringing much of the earlier pulp Sword and Planet stories back into print, as well as publishing a great deal of new, imitative work by a new generation of authors.
There is a fair amount of overlap between Sword and planet and planetary romance although some works are considered to belong to one and not the other. In general, planetary romance is considered to be more of a space opera subgenre, influenced by the likes of A Princess of Mars yet more modern and technologically savvy, while Sword & Planet more directly imitates the conventions established by Burroughs in the Mars series. That is to say that the hero is alone as the only human being from Earth, swords are the weapon of choice, and while the alien planet has some advanced technology, it is used only in limited applications to advance the plot or increase the grandeur of the setting. In general the alien planet will seem to be more medieval and primitive than Earth. This leads to anachronistic situations such as flying ships held aloft by anti-gravity technology, while ground travel is done by riding domesticated native animals.