So let me share a bit.
A Larger World: I always keep in mind that I am not making one-shots stories, I am developing a world with its own logic. I am not writing Love, American Style. Nor the X-Files. Virtually every adventure references the larger setting. This demands that I keep solid notes and that larger adventures have prep.
No Status Quo: Characters change; dungeons get cleared out; NPCs die. So why doesn't the campaign change?
I change things. There are ruined villages where monsters killed the peasants. There are new villages where adventurers moved people they saved. You fail in your mission to relieve a frontier guard tower? NPCs aren't going to swoop in and save it just so the border stays the same. Nope - in my campaign the tower falls, the orcs move on, and NPCs are dragged off tot he slave pens. The PCs insulted the Duke? They better figure out how to fix that!
Game Balance is for Chumps: Number one cause of character death in my campaign? Players thinking I'll save them.
In my campaign parties that seek out trouble and never run are called 'TPKs'. At the same time, sometimes you have a 7th level party encountering a lone goblin scout, so it all evens out.
Random Rolls Prevent Blandness: We all have favorites and habits. If I am not careful something like 40% of my dungeons are about undead. I also have a habit of inserting similar magic items into treasure. Using tables to generate monsters and treasure forces me to be more creative and less predictable.
Preparing for an Adventure Means Being Ready To Improvise: I have long lists of things; village names; tavern names; NPCs; etc. I have charts to determine weather, encounters, and more. I have almost 6,000 pages of notes on my AD&D campaigns.
Yes. Really. My wife insists, insists, this is a low estimateDo they want to teleport themselves to Yashima (Japanland)? I'll break out my maps and notes. Ember wants a condo in the City of Brass? I: grab a writeup for a merchant in the blue folder and make him a Jann; grab my map of the City of Brass from the green folder; hit the basement office for my notes on efreeti in the notebooks in box #7. Ten minutes after he asks I have names, places, etc. - all consistent, all plugged in.
"Whoa, whoa, whoa. Rick, I don't have 6,000 pages of notes on a 38 year old campaign!"
Sure. But where do you think my notes came from?
The point is when you improvise, write it down. Sometimes your very best creative bits hit at the moment as total improv - don't throw that away! In 2010 the party killed a flind and had a random encounter with a merchant; they sold a ton of stuff to him. I added the merchant to my NPC box. In 2014 a different party was travelling along the road and ran into a merchant. One of the things they purchased was a flind bar....
If you haven't figured it out, the last point is
That's the basics I keep in mind!