1. Write through inspiration.
What the heck do I mean by this? I mean listen to a song you really like (or maybe just one that everybody else likes) and then grab your thunder - axe (the term I like to use meaning "guitar") and start playing something. Try not to look at the tab for the song though. Now, I want you to just play something, at either the same tempo and timing, start at the same starting note as the song (or something similar), play with the same feel or whatever you want. Just think of something from the song that you really like, and just sort of fool around until you get somewhere. My favorite approach with this method is starting in the same general area of the fretboard as a riff you really like. And yes, doing it this way means you will probably have to look at a tab, but you don't want to copy the song, so just simply glance at the tab, and then begin. Good riffs are something you have to fool around with to get good at. I'll give you some examples of riffs I have made that complement this approach (songs used for inspiration will be named first, then the artist, and then the description):
- Sweet Child O' Mine (Guns N' Roses) - one of my first and in many people's opinions, my best one, came from me starting at the twelfth fret area, and making an arpeggio riff with some distortion. Sounds sort of space-ish. This song was made when I was learning arpeggios.
- Black Dog (Led Zeppelin) - again, another riff where I started in the same area (technically known as "The Key" of a song), and created sort of a blues-ish, jazz-like riff, but still sounds very different from the original song. Not as fast paced as Black Dog, but a great riff none the less.
- Hotel California (The Eagles) - this riff was made from the "feel" of Hotel California, rather than using the same key, which in this song's case uses a capo at the fifth fret (the key of A). Great rock riff, that sounds as though people could dance to it.
Needless to say, this is quite a good approach to use. However, it works better when you are first starting out, or not so good, because:
1) It gives you something to practice to help "you" get better and;
2) You will learn techniques as you learn how to play, and you will practice them, and practice songs with them in it.
Thus you will make a song similar (maybe). Plus, you may not be able to play the song inspiring you anyway, so there will be no need to worry about copying, now will there? You don't have to be a begginer, but I find it easier to use this approach when you are.
2. The "Holes" Method.
I call this method the "Holes" method because it's like this. You make an original riff, or a riff of some kind, try to add to it, but it doesn't go with it, (thus you fall into a hole) but you still think it has potential (you come out of another hole). I have done this many times, although I don't plan to use any of the riffs I can remember. However, this method is powerful, because you are trying to make riffs for one song, and many of your failed attempts become riffs for other songs. One riff I tried to use to complete the "Black Dog" inspired song mentioned above, kind of went with it, but didn't. So now, if I want, I have another riff in my repretoire of original ones. So remember; you may want to keep those riffs that you thought were garbage, and make something of them. One major advantage to this method, is if you want to make an album with similar, but different sounding songs, that you want to define your "unchanging sound." Anyway, thats an idea.
3. "Open" up.
Use open notes in your songs, even when you are at the 15th fret, you may come up with something that can blow people out of the water, just by adding an open note or two. I have a couple good riffs that use open notes in them, and they sound great. Good for making more "evil" sounding songs. Eddie Van Halen uses lots of open notes in his soloing, so why not use them in your riffs?
4. Find your groove and favorite stuff.
Okay, now I'm sure that many people, like me, have a "favorite chord" that they just love. Whether it be the E minor, or the F diminished, you can find chords that you just love so much, and think, "Damn thats good. Lets make some tunes out of it." And thus, a dynasty will begin. Or at least, a whole new outlook on making your riffs. Take me for instance. I just love the a minor chord (preferabally the open one) because it sounds great, has many other places to go that are easily accessible (Asus, AMaj, A7, Am7 etc) and just overall appeals to my ear. I also like suspended chords in general, as they have that great tone that I find just right. Anyway, you can make great riffs, using just one chord letter. I made a very memorable riff, starting with our friend the A minor, and adding sevenths or what not. Not too many songs use a one chord type of riff, so it may be a good thing to check out.
5. Use unorthodox means.
Great riffs are just waiting to be unlocked. however, you may have to do some sneaky things to find them. You can try stretches that you can barely make, and make some good arpeggios out of them, or you can make some odd chords that you don't think exist (which, they do) or play with techniques or styles that you would never use. Experiment.
6. Let your fingers do the walking.
One of the best methods, is improvisinng. You don't even have to be good at improv, you just have to be playing. I have many great riffs made when I was talking to my friends, or watching tv. Just get relax, don't think about it and play. Just play. I can almost guarantee that one day, when you aren't thinking about what you are doing, you will come up with something that sparks your attention.
7. Unleash your emotion.
The most obvious method is to play what you feel. If you are feeling sad, play the guitar, and you will most likely come up with a sad riff. A great one to use (especially if your girlfriend/boyfriend breaks up with you; or better yet dumps you. Not trying to be a jerk, but it's the truth.
To conclude, I just want to say that, these are just ideas that you may never have thought or overlooked. If you already knew about these, then all the power to you. I hope I have sparked your interest and influenced your composition skills at least a little bit. One thing I didn't mention is to try moving open chords to higher frets. You an make numerous original riffs like this. Anyway, don't give up; you'll find at least one good riff.