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

After GZIP compression these minified files vary in size:
Boot
  123264 bytes (120.4k)
CDN
cdnjs
  102844 bytes (100.4k)
CDN
gzip -6 (default)
  101794 bytes (99.4k)
local copy
cdnhttps
  101685 bytes (99.3k)
CDN
gzip -9
  101397 bytes (99.0k)
local copy
unpkg
  100977 bytes (98.6k)
CDN
libdeflate -12
  97605 bytes (95.3k)
local copy
7zip -mx=9 -tgzip
  97457 bytes (95.2k)
local copy
pigz -11 -n
  97182 bytes (94.9k)
local copy
kzip -s0 -rn -b0
  97110 bytes (94.8k)
local copy
Zopfli
  97089 bytes (94.8k)
local copy
Zopfli (defluff)
  97088 bytes (94.8k)
local copy

perma-link to the smallest file on my server:
http://minime.stephan-brumme.com/files/threejs/three-r66.min.js (or via HTTPS)

You will automatically get the smallest ThreeJS 66 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 3888 bytes by using my ThreeJS 66 Zopfli version instead of the best available CDN (4.00% smaller than unpkg, 97089 vs. 100977 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 --mls64 --bsr13 --lazy --ohh

(found January 28, 2017)
Description Value Parameter
iterations 1000000  --i1000000
maximum blocks 8  --mb8
maximum length score 64  --mls64
block splitting recursion 13  --bsr13
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 (97088 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/r66/build/three.min.js --location | md5sum
1edb628be733ee738c5ea17cec8d6134  -
curl --silent --compressed https://minime.stephan-brumme.com/files/threejs/three-r66.min.zopfli.js.gz | md5sum
1edb628be733ee738c5ea17cec8d6134  -

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

These CDNs send you the original file:
CDN Size (compressed) MD5 (uncompressed) Timestamp
Boot 123264 bytes 1edb628be733ee738c5ea17cec8d6134 (invalid)
cdnjs 102844 bytes 1edb628be733ee738c5ea17cec8d6134 (invalid)
cdnhttps 101685 bytes 1edb628be733ee738c5ea17cec8d6134 December 24, 2015 @ 07:36

And some CDNs send you a different file:
CDN Size (compressed) MD5 (uncompressed) Comment / Diff Timestamp
unpkg 100977 bytes c0b6058458c3d9ff556732ba3059af75 < // three.js - http://github.com/mrdoob/three.js
< 'use strict';var THREE={REVISION:"66"};self.console=self.c [...]
< (function(){for(var a=0,b=["ms","moz","webkit","o"],c=0;c< [...]
< self.clearTimeout&&(self.cancelAnimationFrame=function(a){ [...]
< THREE.NormalBlending=1;THREE.AdditiveBlending=2;THREE.Subt [...]
< THREE.SrcAlphaSaturateFactor=210;THREE.MultiplyOperation=0 [...]
< THREE.LinearFilter=1006;THREE.LinearMipMapNearestFilter=10 [...]
< THREE.RGB_S3TC_DXT1_Format=2001;THREE.RGBA_S3TC_DXT1_Forma [...]
< THREE.Color.prototype={constructor:THREE.Color,r:1,g:1,b:1 [...]
< c:0.5>c?b:c<2/3?a+6*(b-a)*(2/3-c):a};b=0.5>=c?c*(1+b):c+b- [...]
[...]
July 11, 2016 @ 15:49

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

Other Versions

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

97, 96, 95, 94, 93, 92, 91, 90, 89, 88, 87, 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
97089 bytes -4 bytes zopfli --i1000000 --mls64 --bsr13 --lazy --ohh January 28, 2017 @ 13:27
97093 bytes -1 byte zopfli --i100000 --mls64 --bsr13 --lazy --ohh December 29, 2015 @ 16:15
97094 bytes -3 bytes zopfli --i100000 --mls64 --bsr22 --lazy --ohh December 29, 2015 @ 14:17
97097 bytes -4 bytes zopfli --i100000 --mls256 --bsr17 --lazy --ohh December 29, 2015 @ 11:00
97101 bytes -1 byte zopfli --i10000 --mls256 --bsr17 --lazy --ohh November 16, 2015 @ 16:23
97102 bytes -12 bytes zopfli --i10000 --mls64 --bsr13 --lazy --ohh November 16, 2015 @ 08:30
97114 bytes -1 byte zopfli --i1000 --mls256 --bsr17 --lazy --ohh November 16, 2015 @ 02:02
97115 bytes -19 bytes zopfli --i1000 --mls64 --bsr13 --lazy --ohh November 16, 2015 @ 02:02
97134 bytes -4 bytes zopfli --i1000 --mls256 --bsr21 --lazy --ohh November 16, 2015 @ 01:58
97138 bytes zopfli --i100 --mls256 --bsr40 --lazy --ohh November 15, 2015 @ 11:42

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

Most recent activity on February 2, 2017 @ 14:48.

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
97168 97222 97224 97207 97203 97169 97337 97339 97244 97176 97242 97247 97215 97210 97302
97257 97312 97323 97321 97131 97199 97177 97148 97140 97229 97185 97169 97202 97234 97292
97216 97214 97275 97157 97341 97274 97213 97224 97210 97195 97159 97307 97175 97282 97298
97147 97173 97174 97210 97168 97185 97167 97127 97156 97188 97250 97186 97191 97214 97306
97324 97145 97306 97216 97185 97224 97147 97140 97148 97165 97156 97227 97175 97187 97291
97215 97296 97301 97163 97164 97166 97174 97140 97225 97239 97291 97285 97144 97147 97287
97280 97277 97298 97323 97278 97257 97255 97140 97223 97161 97210 97208 97148 97159 97193
97321 97288 97297 97166 97196 97173 97176 97149 97235 97174 97162 97167 97165 97222 97291
97329 97317 97285 97164 97329 97161 97131 97138 97217 97185 97177 97153 97180 97280 97286
97303 97309 97293 97172 97163 97089 97177 97134 97159 97189 97178 97165 97183 97142 97292
97160 97191 97162 97167 97165 97179 97111 97130 97168 97156 97257 97158 97166 97161 97288
97149 97194 97181 97164 97165 97181 97179 97130 97223 97156 97170 97171 97189 97234 97282
97177 97173 97170 97166 97164 97181 97138 97131 97215 97155 97193 97181 97202 97177 97283
97181 97222 97177 97175 97165 97178 97169 97097 97239 97172 97177 97163 97188 97178 97191
97188 97192 97162 97174 97168 97124 97187 97123 97158 97148 97185 97156 97141 97158 97288
97198 97188 97181 97165 97166 97182 97177 97145 97238 97173 97155 97167 97175 97155 97285
97213 97175 97185 97167 97167 97171 97167 97149 97175 97193 97167 97160 97146 97163 97289
97178 97169 97184 97175 97153 97179 97178 97125 97145 97151 97167 97163 97185 97272 97286
97294 97290 97297 97165 97164 97094 97134 97136 97180 97189 97174 97154 97151 97150 97288
97294 97290 97294 97167 97175 97164 97167 97098 97154 97150 97244 97187 97199 97188 97290
97296 97291 97167 97162 97164 97096 97175 97137 97150 97191 97157 97173 97144 97148 97287
97144 97188 97182 97168 97157 97174 97178 97137 97231 97169 97172 97177 97191 97149 97289
97149 97177 97172 97172 97163 97170 97170 97094 97240 97192 97175 97178 97150 97215 97291

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 97138 bytes 100%
1,000 97114 bytes -24 bytes 100%
10,000 97101 bytes -13 bytes 100%
100,000 97093 bytes -8 bytes 1.74%
1,000,000 97089 bytes -4 bytes 0.29%
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
97110 bytes +21 bytes (+0.02%)
97561 bytes +472 bytes (+0.49%) +451 bytes
97443 bytes +354 bytes (+0.36%) +333 bytes
97445 bytes +356 bytes (+0.37%) +335 bytes
97371 bytes +282 bytes (+0.29%) +261 bytes
97339 bytes +250 bytes (+0.26%) +229 bytes
97232 bytes +143 bytes (+0.15%) +122 bytes
97205 bytes +116 bytes (+0.12%) +95 bytes
97169 bytes +80 bytes (+0.08%) +59 bytes

Non-DEFLATE Algorithms

Archivers based on completely different compression algorithms often produce superior results.
Unfortunately, browsers only support gzip compression at the moment.
However, support for Brotli is constantly growing - but your browser doesn't support it.
Algorithm Program Parameters Size Compared To Best Zopfli
ZPAQ (Wikipedia) zpaq zpaq -method 69 66793 bytes -30296 bytes (-31.20%)
RAR (proprietary) RAR rar a -m5 -md64m -mc63:128t -mt1 76928 bytes -20161 bytes (-20.77%)
PPMd (Wikipedia) 7zip 7za a -mx=9 -m0=ppmd 81365 bytes -15724 bytes (-16.20%)
Brotli (Wikipedia) brotli brotli -q 11 83261 bytes -13828 bytes (-14.24%)
LZMA2 (Wikipedia) xz xz -9 83844 bytes -13245 bytes (-13.64%)
Zstandard (Wikipedia) zstd zstd -19 89176 bytes -7913 bytes (-8.15%)
Burrows-Wheeler transform (Wikipedia) bzip2 bzip2 -9 89480 bytes -7609 bytes (-7.84%)

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 2018.
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