Honestly, I have no idea most of the time. Most of my ideas just pop into my mind, sometimes tangentially based on something I was doing or reading or listening to at the time. Often I find a gap in the canon where I could conceivably fit something interesting and just work from there (19-5 BBY is the setting of a lot of my ideas, for example). I don’t really go for common tropes, but I know that plenty of people can pick a trope they find intriguing and figure out a story around that premise. I also find that reading outside your normal genre can be a huge source of inspiration; as you may have guessed, I both read and write a lot of sci-fi, so when I get stuck in a bit of a hole I like to go for something fantasy or non-fiction.
Other than that, I would definitely recommend that you write down every idea you have, however simple or small. Most of mine are very vague and need a whole lot of development before I could even think about going through with them, and I always feel silly writing them down, but it does help. When it comes to actually developing the story, it helps me to map out exactly where I want certain things to go (others I will leave open) and I find that seeing it laid out like that often gives me inspiration for the next bits. But, of course, everyone works in their own way.
Hope that helps!
~ Jacen
