Choose a version:
50% The original file has 820621 bytes (801.4k) and is available from the project website.
There you can find the official minified version, too, which brings down the size to 411428 bytes (401.8k, 50%).

After GZIP compression these minified files vary in size:
Boot
  117646 bytes (114.9k)
CDN, direct link
cdnjs
  98372 bytes (96.1k)
CDN, direct link
gzip -6 (default)
  97451 bytes (95.2k)
local copy
cdnhttps
  97326 bytes (95.0k)
CDN, direct link
gzip -9
  97020 bytes (94.7k)
local copy
libdeflate -12
  93717 bytes (91.5k)
local copy
7zip -mx=9 -tgzip
  93617 bytes (91.4k)
local copy
pigz -11 -n
  93217 bytes (91.0k)
local copy
kzip -s0 -rn -b0
  93179 bytes (91.0k)
local copy
Zopfli
  93134 bytes (91.0k)
local copy
Zopfli (defluff)
  93133 bytes (91.0k)
local copy

perma-link to the smallest file on my server:
http://minime.stephan-brumme.com/files/threejs/three-r58.min.js

You will automatically get the smallest ThreeJS 58 file, ETag caching is available and
if your browser doesn't support GZIP decompression then the uncompressed version will be sent.

Currently best Zopfli settings

Save 4192 bytes by using my ThreeJS 58 Zopfli version instead of the best available CDN (4.50% smaller than cdnhttps, 93134 vs. 97326 bytes):
You can use my super-compressed files for whatever purpose you like as long as you respect the library's original license agreement.
There are no restrictions from my side - but please avoid hot-linking if you run a high-traffic website.

These command-line settings yielded the best compression ratio so far (Linux version of zopfli-krzymod):
zopfli --i1000000 --mb8 --mls8192 --bsr20 --lazy --ohh

(found February 10, 2017)
Description Value Parameter
iterations 1000000  --i1000000
maximum blocks 8  --mb8
maximum length score 8192  --mls8192
block splitting recursion 20  --bsr20
lazy matching in LZ77 yes  --lazy
optimized Huffman headers yes  --ohh
initial random W for iterations 1  --rw1
initial random Z for iterations 2  --rz2

Even Smaller Files Thanks To Defluff

Zopfli's output can be further optimized by the defluff tool.
In this particular case, defluff saves 1 more byte (93133 bytes).

Verify file integrity

After decompression, my uncompressed files are identical to the original ones:

MD5:
curl --silent --compressed https://raw.githubusercontent.com/mrdoob/three.js/r58/build/three.min.js --location | md5sum
7829aa3c2c1e79d0932781b2035656c2  -
curl --silent --compressed http://minime.stephan-brumme.com/files/threejs/three-r58.min.zopfli.js.gz | md5sum
7829aa3c2c1e79d0932781b2035656c2  -

SHA1:
curl --silent --compressed https://raw.githubusercontent.com/mrdoob/three.js/r58/build/three.min.js --location | sha1sum
e50663d3324e16790fefc0a0bc229798138d7cb1  -
curl --silent --compressed http://minime.stephan-brumme.com/files/threejs/three-r58.min.zopfli.js.gz | sha1sum
e50663d3324e16790fefc0a0bc229798138d7cb1  -

All listed CDNs deliver identical contents:
CDN Size (compressed) MD5 (uncompressed) Timestamp
Boot 117646 bytes 7829aa3c2c1e79d0932781b2035656c2 (invalid)
cdnjs 98372 bytes 7829aa3c2c1e79d0932781b2035656c2 (invalid)
cdnhttps 97326 bytes 7829aa3c2c1e79d0932781b2035656c2 December 24, 2015 @ 07:36

Note: only the MD5 hashes are shown to keep things simple.

Other Versions

Available ThreeJS versions at minime.stephan-brumme.com:

86, 85, 84, 83, 82, 81, 80, 79, 78, 77, 76, 75, 74, 73, 72, 71, 70, 69, 68, 67, 66, 65, 64, 63, 62, 61, 60, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50

The project site contains an overview how well these versions were compressed.
Other interesting projects are AngularJS, BackboneJS, Bootstrap, D3, Dojo, Ember, jQuery, Knockout, lodash, React, Socket.IO, UnderscoreJS and Vue.

Changelog

Best Zopfli parameters so far:
Size Improvement Parameters Found
93134 bytes -6 bytes zopfli --i1000000 --mls8192 --bsr20 --lazy --ohh February 10, 2017 @ 10:21
93140 bytes -3 bytes zopfli --i100000 --mls8192 --bsr20 --lazy --ohh December 28, 2015 @ 17:17
93143 bytes -17 bytes zopfli --i10000 --mls8192 --bsr20 --lazy --ohh November 16, 2015 @ 01:19
93160 bytes -2 bytes zopfli --i1000 --mls8192 --bsr20 --lazy --ohh November 15, 2015 @ 18:14
93162 bytes -1 byte zopfli --i1000 --mls512 --bsr13 --lazy --ohh November 15, 2015 @ 18:07
93163 bytes -6 bytes zopfli --i1000 --mls512 --bsr10 --lazy --ohh November 15, 2015 @ 18:04
93169 bytes -2 bytes zopfli --i1000 --mls2048 --bsr40 --lazy --ohh November 15, 2015 @ 17:51
93171 bytes -1 byte zopfli --i1000 --mls8192 --bsr18 --lazy --ohh November 15, 2015 @ 17:44
93172 bytes zopfli --i100 --mls8192 --bsr20 --lazy --ohh November 15, 2015 @ 11:05

If there are multiple parameter sets yielding the same compressed size, only the first one found is shown.

Most recent activity on February 11, 2017 @ 09:37.

Heatmaps

This Zopfli heatmap visualizes how compression changes when modifying the --bsr and --mls parameter.
Cell's contents is the best filesize achieved (in bytes, hover with mouse over cells to see number of iterations).

Good parameters are green, bad are red. The best and worst are bold as well.
The brightness of the blue background color indicates how many iterations were processed:
10,000, 100,000 or 1,000,000.
bsr \ mls
2 4 8 16 32 64 128 256 512 1024 2048 4096 8192 16384 32768
bsr \ mls
2 4 8 16 32 64 128 256 512 1024 2048 4096 8192 16384 32768
93323 93341 93315 93315 93304 93319 93327 93332 93329 93305 93310 93355 93283 93278 93342
93315 93296 93258 93272 93284 93319 93235 93242 93227 93217 93250 93313 93239 93304 93320
93377 93350 93267 93264 93237 93259 93247 93217 93173 93224 93240 93269 93305 93221 93305
93275 93266 93267 93263 93263 93258 93233 93234 93238 93296 93260 93253 93224 93286 93306
93275 93266 93261 93329 93274 93222 93253 93249 93205 93267 93252 93259 93196 93274 93281
93364 93282 93347 93277 93283 93234 93243 93262 93204 93295 93208 93256 93230 93213 93230
93281 93264 93315 93264 93270 93217 93228 93220 93138 93261 93241 93221 93144 93237 93328
93265 93267 93304 93378 93232 93236 93235 93277 93200 93279 93266 93266 93296 93282 93329
93345 93271 93326 93260 93326 93238 93237 93219 93251 93267 93232 93243 93232 93253 93281
93276 93317 93337 93329 93266 93232 93219 93215 93154 93210 93247 93230 93236 93286 93286
93264 93267 93334 93258 93332 93260 93261 93252 93249 93293 93242 93253 93234 93300 93296
93298 93327 93330 93261 93265 93228 93216 93213 93208 93248 93273 93261 93215 93230 93305
93285 93264 93337 93330 93265 93236 93226 93213 93267 93293 93254 93263 93237 93315 93332
93365 93277 93306 93330 93280 93311 93246 93273 93265 93296 93239 93218 93228 93285 93293
93351 93291 93330 93330 93330 93222 93239 93215 93177 93276 93238 93228 93156 93210 93277
93264 93265 93325 93354 93219 93238 93251 93220 93265 93267 93228 93263 93154 93296 93283
93254 93264 93314 93311 93228 93234 93213 93213 93198 93251 93154 93216 93134 93216 93294
93265 93264 93265 93254 93331 93255 93239 93260 93244 93248 93217 93258 93164 93240 93297
93365 93266 93250 93261 93382 93251 93241 93215 93252 93266 93238 93224 93250 93291 93298
93281 93265 93311 93328 93266 93237 93218 93209 93217 93228 93225 93233 93232 93290 93345
93312 93265 93313 93257 93263 93231 93260 93254 93254 93217 93161 93230 93163 93294 93304
93262 93265 93333 93328 93321 93259 93243 93215 93224 93218 93163 93250 93228 93276 93288
93278 93265 93262 93259 93263 93254 93238 93252 93252 93183 93160 93229 93161 93270 93276

Due to the Monte Carlo design of my search algorithm, not all parameters have reached the same number of iterations yet:
Iterations Min. Bytes Reduction Coverage
100 93172 bytes 100%
1,000 93160 bytes -12 bytes 100%
10,000 93143 bytes -17 bytes 100%
100,000 93140 bytes -3 bytes 0.87%
1,000,000 93134 bytes -6 bytes 0.58%
10,000,000

KZIP has far less options available for tuning/optimization. I only played around with the number of blocks (parameter -n):
Blocks Min. Bytes Compared To Best Zopfli Compared To Best KZIP
93179 bytes +45 bytes (+0.05%)
93723 bytes +589 bytes (+0.63%) +544 bytes
93673 bytes +539 bytes (+0.58%) +494 bytes
93533 bytes +399 bytes (+0.43%) +354 bytes
93503 bytes +369 bytes (+0.40%) +324 bytes
93403 bytes +269 bytes (+0.29%) +224 bytes
93396 bytes +262 bytes (+0.28%) +217 bytes
93344 bytes +210 bytes (+0.23%) +165 bytes
93362 bytes +228 bytes (+0.24%) +183 bytes

Non-DEFLATE Algorithms

Archivers based on completely different compression algorithms often produce superior results.
Unfortunately, browsers only support gzip compression at the moment.
Algorithm Program Parameters Size Compared To Best Zopfli
ZPAQ (Wikipedia) zpaq zpaq -method 69 63892 bytes -29242 bytes (-31.40%)
RAR (proprietary) RAR rar a -m5 -md64m -mc63:128t -mt1 73661 bytes -19473 bytes (-20.91%)
PPMd (Wikipedia) 7zip 7za a -mx=9 -m0=ppmd 78186 bytes -14948 bytes (-16.05%)
Brotli (Wikipedia) brotli brotli -q 11 79271 bytes -13863 bytes (-14.89%)
LZMA2 (Wikipedia) xz xz -9 80036 bytes -13098 bytes (-14.06%)
ZSTD (Wikipedia) zstd zstd -19 85196 bytes -7938 bytes (-8.52%)
Burrows-Wheeler transform (Wikipedia) bzip2 bzip2 -9 86071 bytes -7063 bytes (-7.58%)

Detailled Analysis

I wrote a DEFLATE decoder in Javascript. Click the button below to start a client-side analysis of the smallest gzipped files (may take a second):


Notes: pigz is a fast open source multi-threaded implementation of gzip written by one of the original authors of gzip.
However, when using compression level 11, pigz actually switches to the slower Zopfli algorithm and isn't multi-threaded anymore.
KrzyMOD's extensions to Zopfli offer the highest level of configuration and is therefore used for my brute-force search.
Ken Silverman wrote the closed-source KZIP compression program and Jonathon Fowler ported it to Linux.
Defluff was created by Joachim Henke; DeflOpt is a tool by Ben Jos Walbeehm.

website made by Stephan Brumme in 2015 and still improving in 2017.
all timestamps are displayed in central european time. see my changelog.
no flash, not even images or external css files - and everything squeezed into a single html file.
which was handsomely compressed before releasing it into the wild internet - obviously.

please visit my homepage and my blog, too.
email: minime (at) stephan-brumme.com