All of these answers aren't very helpful because they are time sensitive.
After doing some research of my own I found that simplejson
is indeed faster than the builtin, if you keep it updated to the latest version.
pip/easy_install
wanted to install 2.3.2 on ubuntu 12.04, but after finding out the latest simplejson
version is actually 3.3.0, so I updated it and reran the time tests.
simplejson
is about 3x faster than the builtin json
at loadssimplejson
is about 30% faster than the builtin json
at dumpsThe above statements are in python-2.7.3 and simplejson 3.3.0 (with c speedups) And to make sure my answer also isn't time sensitive, you should run your own tests to check since it varies so much between versions; there's no easy answer that isn't time sensitive.
import simplejson
# If this is True, then c speedups are enabled.
print bool(getattr(simplejson, '_speedups', False))
UPDATE: I recently came across a library called ujson that is performing ~3x faster than simplejson
with some basic tests.