In hard core technical circles, discussing the relative merits of
these two editors is pretty much verboten. In the past, debates around
this issue have actually become vicious (which is ludicrous when you
think about it) and raged on for literally years. Devotees on either
side would rarely listen to reason, and mostly everyone seemed to
think it was an either/or situation. To be honest, I think that stance
is utter rubbish.
I feel as if I'm uniquely placed to answer this one because I've been
using both for about 25 years now. (15 with almost full time Vim and
First off, I want to slightly challenge your question. It's too
simplistic and there can be no answer to it the way you asked it.
Emacs and vi are both superlative editors for certain types of
things - their strengths give them super powers in very different ways
that lend them to solving some problems more easily than others.
To my mind, if your goal is simply to edit text, Vim might be better
suited to the task. Its modal editing lends itself to lightning fast
text entry, and there is a nearly infinite potential growth curve for
how its various commands and shortcuts can be efficiently brought to
bear in navigating and moving text around.
Through the years, various extension technologies have been added to
Vi (a-la Vim) that enable it to be extended in various ways, but in my
personal hard wrought experience, there are limits as to how far you
can push that extension before the both the editing paradigm and the
mechanics begin to creak and groan under the weight of what you're
trying to accomplish.
For instance, the straw that broke the camel's back for me was trying
to get IDE like method and member auto-completion and refactoring into
the editor. There are various solutions for this in Vim, but they
either just plain didn't work, or if they did de-stabilized my Vim
installation because they required the installation of C shared
libraries that were a pain to build and install. There's nothing quite
like having your editor dump core in the middle of a critical editing
session to make you reconsider your choice of tools.
Note that the above scenario has virtually nothing to do, strictly
speaking, with editing text. It's the result of trying to make Vim
into an IDE, which it isn't.
As others have mentioned Vi/Vim also has the advantage of ubiquity.
It's bundled by default on just about every UNIX system on the planet,
and that's definitely worth noting.
A great resource for Vim users is Vimcasts
I personally think of emacs less as a text editor and more as an
incredibly powerful programming environment hyper optimized for
working with text - the upshot being that it also has very capable
text editing features.
I know that sounds like I'm just playing with words but trust me I'm
not. If you want to create the most incredibly powerful programming
environment utterly customized to your every need, then Emacs is
undoubtedly for you.
It excels at subprocess control, so for instance if you're programming
in Python, emacs will run a Python interpreter for you inside the
editor. Why would you want this you might ask? Because then you can,
while you're coding, try bits and bobs of code out and actually run it
and see how it works. Emacs can even run the Python interpreter on a
remote machine and hook it into your editing session.
At the core of emacs is emacs lisp - elisp is at the heart of emacs's
superpowers. It is the ONLY extension language available in emacs,
but it can do just about anything. You can avoid learning elisp and
still be very productive using emacs, but chances are if you're like
most people you will get sucked in eventually as the lure of sanding
the rough edges off of some mode or other becomes too great :)
You can, if you so choose, use emacs as your entire working
environment - edit, code, chat, manipulate source control (like Git) -
pretty much anything.
This is a common attack non emacs users make "It's not an editor. It's
an operating system!" and I say they're right, but they're also
missing the point :)