Languages are very important, especially if you're doing non-US history. Consider enrolling in intensive language classes before you apply, and see if you can tailor those classes to focus on reading and translation.
You need not have published anything (I haven't) in order to get admitted into a top program, although I'm sure it helps. Nor need your undergraduate thesis be in the field that you're hoping to pursue in grad school. I wrote my thesis in medieval history and will be specializing in international and global history (I actually found a way to broadly link my thesis to my grad school interests).
None of my references were from faculty in my field. One was from my thesis advisor, an up-and-coming medievalist, the other was from a (permanent) visiting prof who teaches modern European history, and the third was from a retired English professor. All three have known me since freshman and sophomore year. So you should get to know your undergraduate professors well: talk to them during office hours, take them out for meals, send them postcards when you're traveling, etc.
For those interested in international and global history, this comes from a Columbia professor who emailed me right after I was admitted there: "One of our primary considerations in choosing candidates is their ability to attract the interest of a wide variety of faculty across the fields."
Read books and articles by the profs at the schools you're applying to, and see if you can integrate their ideas into your statements of purpose. Get people to critique these statements. The best piece of advice that I received was to replace the term "Cold War," at least initially, with "that period which policy-makers and -thinkers objectify as the Cold War." It seemed unnecessarily pedantic at first, but the more I thought about it, the more it made sense in the context of what I was trying to do.
The bulk of my statements of purpose was about my research interests and how they complemented those of specific faculty members at the schools I was applying to. I did however have one paragraph on myself and how my personal background (namely, being an international student who studied in the US) shaped my belief in studying history from a global perspective (though not my specific research interests).
If you're still in college, consider taking a few years off before applying to grad school, unless you're exceptionally well-prepared and absolutely sure you want to be an academic (there's plenty on the perils of grad school in the humanities -- go and read articles by Thomas Bender / William Pannapacker and Tim Burke). See the real world, travel, learn some languages, pursue jobs related to academia (e.g. teaching, journalism, government work, etc.). I think grad schools like it when you possess a certain worldliness.
I had some contact with faculty from the schools I was applying to. Two gave standard, non-committal replies and said that they were looking forward to reading my application. The third -- from Columbia -- had some encouraging words for me, but that was about it.
===
I'll be meeting with a bunch of Columbia faculty and grad students this week, and might have more insights after then.
Looking back, and seeing just how well-qualified some of the people on this forum are, I feel humbled, not to mention incredibly lucky, at having gotten into where I have. Hope the above's useful in some way to all those applying this year. Best of luck!