Science fantasy is an inter- genre of speculative fiction and more specifically of Science Fiction / Fantasy that includes equally the tropes of both fantasy, such as magic, iron age technology, and fantastical creatures like dragons and unicorns, and science fiction, such as technology, spaceships, and so on
According to Wikipedia, some of the main subgenres of science fantasy are:
- Dying Earth 
- Post-apocalypse 
- Planetary romance / Sword and planet  – e.g. Edgar Rice Burroughs‘ John Carter of Mars, essentially, proto-Space Opera rendered absurd and obsolete by modern discoveries of the actual conditions on the surface of Venus and Mars
Everyone has their own definition, and that fact that each of the above has variously been included under straight science fiction and straight fantasy shows how fluid these distinctions and categorisations are; hence my preference for the term Science Fiction / Fantasy, or sff for short .
My own two preferred form of science fantasy, not included in the above list, are Cyberpunk Fantasy and Space Opera Science Fantasy.
Cyberpunk Fantasy is represented exclusively by the roleplaying game franchise Shadowrun which equally includes classic cyberpunk tropes such as hackers and mecgacorps with classic D&D magic and High Fantasy races in a single universe
Space Opera Science Fantasy includes any space opera that combines one or more fantasy elements such as swords, magic, elves, etc with standard Space Opera tropes such as spaceships, energy weapons, galactic empires, robots, and so on. Examples are Star Wars (which despite the fairy tale setting is actually Fantasy Lite), Warhammer 40K (which can be considered science-fantasy-horror, and is more Fantasy Heavy than even Shadowrun), J S Morin‘s Black Ocean series (an FTL version of Joss Whedon’s Firefly, with Fantasy Lite addition), and my own Alcione-verse (again, Fantasy-Lite, but more orientated to the metaphysical than the other examples)
 Wikipedia includes these together, but they are clearly distinct; as post-apocalypse is set in the near future, and Dying Planet thousands or millions of years hence)
 It is not clear why these are placed in two different categories by the Wikipedia editors