* The original Star Wars movie (Episode IV: A New Hope) was released in 1977.
* The first Star Wars novelization, also titled "Star Wars," was released in 1976.
So, technically, the book was released before the movie. However, the book was an adaptation of the movie script, written by Alan Dean Foster. It wasn't an original story that came before the movie.
There were, however, other pre-existing works that George Lucas drew inspiration from for Star Wars. These include:
* "Flash Gordon": A comic strip and film series featuring a space adventurer.
* "The Hidden Fortress": A 1958 Japanese film that Lucas has cited as a major influence on the structure and themes of Star Wars.
* "The Dam Busters": A British war film that inspired the Death Star trench run scene.
So, while the specific book adaptation of the movie came out before the film itself, Star Wars was inspired by other existing works that predate the movie.