What is your dialogue doing?
Dialogue has the power to make a scene feel more active, alive and real. It typically is perceived as fast-paced in comparison with description. It can create character, world, and drive for a story - or it can sound flat and authorial. Here are some of my thoughts on what features make for effective dialogue.
1. Keep dialogue unambiguous and dialogue tags unobtrusive.
By unambiguous I mean that I always try to make sure it's clear who is talking. I've read books, some by quite well known authors, where characters get into disputes and there will be a sequence of five or six lines in which it's just an exchange of dialogue with no tags at all. Now, you can rely quite a bit on the reader's turn-taking instinct. The default assumption in a two-person exchange will be that the two alternate in an orderly fashion. However, in a lengthy exchange it can be easy to lose track of who is saying what. Keeping voices distinct can go a long way toward disambiguating this (I'll come back to this), but judicious use of "said Eris" or "Eris said" is more effective and practically invisible. Another way to disambiguate is to include some internalization from the point of view character. Including internalization is also a great way to show when the pov character isn't telling the truth, without using an obvious tag like "he lied."
I've seen a lot on the internet on the topic of dialogue tags. The general consensus is that one should not use lots of adverbs like "he said angrily" nor should one use lots of fancy words for how to speak "she yelled/thundered/etc." and especially not in combination "he yelled angrily." I think this rule has to do with the fact that dialogue tags stand on their own in the midst of a stream of dialogue, often without the support of surrounding description, and adverbs and tags with special content (not to mention redundant content!) distract from what people are saying. "Said" is relatively invisible, so long as it's not used for every turn. Janice Hardy had a great post on dialogue a few days ago; if you're interested, it's here. I agree with her that it's important to vary the rhythm of the tagging techniques so they don't stand out.
2. Keep characters distinct.
This operates on several levels. The voice of each character should be distinct; people use different styles of speech, sometimes different dialects or even different languages. Their speech will have different rhythms. Each person should speak out of his or her own motives. In addition to this, keep in mind that any two people will not talk about things in the same way. Each one will bring a worldview to his or her contribution.
3. Make sure people speak for their own purposes.
Especially when you're worldbuilding, or working with a complicated plot, it's tempting to turn to dialogue to get information across. This is actually okay, so long as the dialogue also functions and makes sense for the characters. I've often mentioned avoiding "As you know, Bob" dialogue in which people tell one another things they already know just for the purposes of exposition.
However. Even if you're being indirect and slipping the key information into the dialogue, it's vital to ask yourself two fundamental questions: a. Why would these people talk? b. Why would they talk about this? If you can't answer these questions, then whatever your characters say will fall flat. In real situations, people don't talk without motivation. And even if they talk vacuously, it will be for a reason - because they're nervous, for example. It's perfectly okay for dialogue to serve the author's purposes, but it has to serve the character's purpose first.
4. Be aware of all the many things that dialogue can convey.
Once you've gotten in touch with what messages your character wants to deliver and why, think about all the subtler messages that can be conveyed in the way they say what they say. Emotional states. Social status information. Worldbuilding information. Very often these things don't need to be out-and-out explained in the dialogue, only hinted at (hidden in plain sight).
I find it so exciting when I write a line of dialogue, and I can not only feel the purpose in it, but sense the depth of character motivation and world behind it. I hope you get to experience this too.