Undoubtedly one of the most exciting moments in The Elder Scrolls V: Skyrim is when that music kicks up, guards prepare for battle and you see the shadow of a Dragon on the ground. Regardless of your level, fighting a Dragon is no laughing matter. So to help you out, I've put together a little primer on how to not train, but kill a Dragon.
Whether you're going out hunting a known Dragon, or just expect to see one in the country side soon, the most important part of Dragon combat is preparation. You need to maximize your encumbrance points as much as possible. If you're carrying around a bunch of armor and weapons to sell, fights are going to be a more complicated affair. I suggest unloading all your excess armor and weapons at city shops every chance you get. While you're there, take the time to hit up the blacksmith to make sure you have your armor and weapons upgraded. Smelt your ore if you have any, and go to town on the forge.
Other than making sure you won't be over-encumbered, either make or buy a bunch of health, magick, stamina and resistance potions. Health and magick shouldn't really be that much of a surprise, you're going to be using a lot of magicka and Dragons can dish out a bunch of damage. The stamina potions come into play more when dealing with Dragons that have a Frost shout - ice damage in Skyrim also causes stamina damage. And once you've figured out what kind of Dragon you have on your hands, down a resistance potion attuned to that element.
As for spells and weapons, I've found that Frost spells work well for keeping them grounded a bit longer, and you'll probably want to use whatever weapon you've been using all game already. I've been using a one handed weapon and a shield, and using the shield bash to stun the Dragon lets me get in a few extra hits, but it really depends on your play style here.
The other thing to keep in mind is where you are in Skyrim - the East and North parts of the land are more mountainous and have harsher terrain, which can make fighting a lot more complicated. Take a second or two before you head into battle to make sure you know where the cliff edges are and such. The West and South especially are more barren, so you have little natural cover, but more room to run and maneuver. If you encounter a random Dragon in one of the smaller settlements around Skyrim, you got lucky. Not only do the buildings provide cover from the shouts, but the townspeople will also attack the Dragon, which will make fighting it much simpler.
One other possible preparation you can make, if you have the coin, is to hire one of the mercenaries that can be found in the larger cities' taverns. If nothing else, they'll provide a lovely distraction for the Dragon to chew on while you whack him with your sword.
Once you've actually started fighting a Dragon, you're first move should be buffing your character while the Dragon is still doing its menacing fly-over. Cast whatever Alteration spell you have to raise your armor rating, and boost your health and magick with potions if you have them. Once the beast finally hits Terra Firma, lay into it with your Frost spell. Do as much damage as you can, and when you run out of magick, switch to your weapon. Heal yourself when you get low on health, or when it's flying around. Don't be stingy with the healing either, these beasts can dish out a solid chunk of damage in one hit with their bite. Their wing attack is their weakest one, while the tail is in the middle ground and their shouts do plenty too.
Your best weapon against any Dragon is your voice - learn and use the Dragon Shouts in the World. The Shout that the main quest puts into your lap, Unrelenting Force, works great as a stun, with a small amount of damage, but your best bet is the Marked For Death Shout. In order to get the first word, seek out the Dark Brotherhood as fast as you feel comfortable doing. This Shout causes armor and health damage, which makes your job a whole lot easier. Of course, in order to unlock Marked for Death, you need to kill a Dragon first to gain its soul. Again, don't be stingy with the Shouts or Souls - unlock whichever Shouts you feel like you need as soon as you get a soul, and since there really isn't any limit to the number of Shouts you can do, other than the cooldown period, just keep using them on the Dragon.
Keep hitting the Dragon when it's on the ground with your Shouts, spells and weapon and healing when it's flying around and you should be able to beat the beast with relative ease. Just don't underestimate how much damage they can do - in a short amount of time too. When it falls, you absorb it's soul, and have a lovely skeleton in front of you - Dragon Bones will fetch a nice price in markets, and the Scales can be used to make armor with a Smithing skill of 100, plus Dragons usually have a good amount of gold on them.
Follow these tips and you'll be the Dragonslayer in no time at all.