Choose a version:
47% The original file has 455378 bytes (444.7k) and is available from the project website.
There you can find the official minified version, too, which brings down the size to 215933 bytes (210.9k, 47%).

After GZIP compression these minified files vary in size:
Boot
  83001 bytes (81.1k)
CDN, direct link
cdnjs
  73400 bytes (71.7k)
CDN, direct link
gzip -6 (default)
  72954 bytes (71.2k)
local copy
jsdelivr
  72784 bytes (71.1k)
CDN, direct link
gzip -9
  72668 bytes (71.0k)
local copy
libdeflate -12
  69861 bytes (68.2k)
local copy
7zip -mx=9 -tgzip
  69593 bytes (68.0k)
local copy
kzip -s0 -rn -b7
  69285 bytes (67.7k)
local copy
pigz -11 -n
  69131 bytes (67.5k)
local copy
Zopfli
  69047 bytes (67.4k)
local copy
Zopfli (defluff)
  69045 bytes (67.4k)
local copy

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

You will automatically get the smallest D3 4.7.3 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 3737 bytes by using my D3 4.7.3 Zopfli version instead of the best available CDN (5.41% smaller than jsdelivr, 69047 vs. 72784 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 --mls512 --bsr17 --lazy --ohh

(found May 4, 2017)
Description Value Parameter
iterations 1000000  --i1000000
maximum blocks 8  --mb8
maximum length score 512  --mls512
block splitting recursion 17  --bsr17
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 2 more bytes (69045 bytes).

Verify file integrity

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

MD5:
curl --silent --compressed https://raw.githubusercontent.com/mbostock/d3/v4.7.3/d3.zip --location | md5sum
a5c4c8664b5b3e762eca5ed5910ed90d  -
curl --silent --compressed http://minime.stephan-brumme.com/files/d3/d3-4.7.3.min.zopfli.js.gz | md5sum
a5c4c8664b5b3e762eca5ed5910ed90d  -

SHA1:
curl --silent --compressed https://raw.githubusercontent.com/mbostock/d3/v4.7.3/d3.zip --location | sha1sum
766c5de91965b59bb26e7b4d5ab625a7b49e3fc6  -
curl --silent --compressed http://minime.stephan-brumme.com/files/d3/d3-4.7.3.min.zopfli.js.gz | sha1sum
766c5de91965b59bb26e7b4d5ab625a7b49e3fc6  -

All listed CDNs deliver identical contents:
CDN Size (compressed) MD5 (uncompressed) Timestamp
Boot 83001 bytes a5c4c8664b5b3e762eca5ed5910ed90d March 17, 2017 @ 06:22
cdnjs 73400 bytes a5c4c8664b5b3e762eca5ed5910ed90d March 13, 2017 @ 17:33
jsdelivr 72784 bytes a5c4c8664b5b3e762eca5ed5910ed90d March 13, 2017 @ 17:35

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

Other Versions

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

4.9.1, 4.9.0, 4.8.0, 4.7.4, 4.7.3, 4.7.2, 4.7.1, 4.7.0, 4.6.0, 4.5.0, 4.4.4, 4.4.3, 4.4.2, 4.4.1, 4.4.0, 4.3.0, 4.2.8, 4.2.7, 4.2.6, 4.2.5, 4.2.4, 4.2.3, 4.2.2, 4.2.1, 4.2.0, 4.1.1, 4.1.0, 4.0.0,
3.5.17, 3.5.16, 3.5.15, 3.5.14, 3.5.13, 3.5.12, 3.5.11, 3.5.10, 3.5.9, 3.5.8, 3.5.7, 3.5.6, 3.5.5, 3.5.4, 3.5.3, 3.5.2, 3.5.1, 3.5.0, 3.4.13, 3.4.12, 3.4.11, 3.4.10, 3.4.9, 3.4.8, 3.4.6, 3.4.5, 3.4.4, 3.4.3, 3.4.2, 3.4.1, 3.4.0, 3.3.13, 3.3.12, 3.3.11, 3.3.10, 3.3.9, 3.3.8, 3.3.7, 3.3.6, 3.3.5, 3.3.4, 3.3.3, 3.3.2, 3.3.1, 3.3.0, 3.2.8, 3.2.7, 3.2.6, 3.2.5, 3.2.4, 3.2.3, 3.2.2, 3.2.1, 3.2.0, 3.1.10, 3.1.9, 3.1.8, 3.1.7, 3.1.6, 3.1.5, 3.1.4, 3.1.3, 3.1.2, 3.1.1, 3.1.0, 3.0.8, 3.0.7, 3.0.6, 3.0.5, 3.0.4, 3.0.3, 3.0.2, 3.0.1, 3.0.0

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

Changelog

Best Zopfli parameters so far:
Size Improvement Parameters Found
69047 bytes -2 bytes zopfli --i1000000 --mls512 --bsr17 --lazy --ohh May 4, 2017 @ 00:24
69049 bytes -1 byte zopfli --i100000 --mls512 --bsr17 --lazy --ohh May 3, 2017 @ 09:36
69050 bytes -5 bytes zopfli --i100000 --mls512 --bsr12 --lazy --ohh May 3, 2017 @ 03:25
69055 bytes -11 bytes zopfli --i10000 --mls512 --bsr12 --lazy --ohh April 29, 2017 @ 04:27
69066 bytes -3 bytes zopfli --i1000 --mls512 --bsr12 --lazy --ohh April 28, 2017 @ 15:40
69069 bytes -23 bytes zopfli --i1000 --mls4 --bsr19 --lazy --ohh April 28, 2017 @ 15:36
69092 bytes zopfli --i100 --mls512 --bsr12 --lazy --ohh April 28, 2017 @ 14:20

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

Most recent activity on May 4, 2017 @ 11:15.

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
69326 69326 69340 69454 69457 69412 69345 69308 69305 69305 69322 69301 69297 69270 69298
69336 69323 69126 69102 69153 69105 69158 69112 69117 69249 69203 69230 69214 69228 69227
69110 69062 69162 69066 69085 69073 69244 69095 69124 69221 69212 69228 69200 69233 69228
69091 69101 69075 69071 69062 69099 69287 69197 69205 69203 69212 69236 69237 69222 69240
69087 69089 69087 69067 69234 69311 69272 69240 69274 69218 69211 69229 69233 69217 69215
69061 69062 69081 69064 69066 69068 69201 69208 69181 69206 69206 69095 69246 69151 69213
69068 69063 69083 69074 69236 69200 69242 69221 69198 69190 69209 69228 69234 69204 69226
69059 69065 69077 69066 69065 69066 69243 69242 69066 69189 69187 69228 69237 69211 69125
69060 69063 69067 69076 69196 69202 69244 69199 69050 69206 69187 69220 69224 69205 69241
69064 69064 69076 69064 69188 69194 69240 69232 69194 69203 69201 69228 69215 69147 69132
69113 69069 69076 69062 69194 69200 69238 69192 69191 69207 69201 69222 69214 69216 69126
69063 69064 69078 69063 69063 69235 69241 69211 69203 69200 69200 69229 69209 69212 69233
69098 69097 69071 69064 69191 69239 69195 69212 69066 69199 69210 69219 69242 69177 69115
69105 69062 69073 69063 69194 69236 69240 69205 69047 69163 69201 69073 69231 69200 69122
69101 70155 70152 69183 69228 69188 69241 69205 69238 69164 69199 69223 69225 69207 69257
69063 69062 69074 69281 69184 69211 69239 69204 69196 69161 69174 69216 69215 69205 69214
69066 69062 69231 69188 69183 69183 69238 69210 69240 69167 69161 69221 69181 69204 69236
69069 69064 69070 69062 69269 69313 69241 69258 69199 69167 69163 69190 69194 69203 69129
69139 69063 69071 69063 69237 69232 69243 69203 69244 69167 69176 69193 69187 69208 69252
69105 69061 69069 69064 69067 69063 69190 69205 69068 69162 69163 69220 69183 69205 69122
69103 69065 69069 69067 69065 69067 69239 69210 69050 69172 69203 69214 69184 69244 69110
69104 69062 69071 69066 69184 69246 69245 69210 69207 69166 69164 69191 69180 69212 69231
69107 69065 69069 69211 70133 69217 69194 70132 69067 69167 69169 69180 69187 69193 69230

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 69092 bytes 100%
1,000 69066 bytes -26 bytes 100%
10,000 69055 bytes -11 bytes 100%
100,000 69049 bytes -6 bytes 0.87%
1,000,000 69047 bytes -2 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
69308 bytes +261 bytes (+0.38%) +23 bytes
70620 bytes +1573 bytes (+2.28%) +1335 bytes
70299 bytes +1252 bytes (+1.81%) +1014 bytes
69429 bytes +382 bytes (+0.55%) +144 bytes
69309 bytes +262 bytes (+0.38%) +24 bytes
69318 bytes +271 bytes (+0.39%) +33 bytes
69328 bytes +281 bytes (+0.41%) +43 bytes
69285 bytes +238 bytes (+0.34%)
69292 bytes +245 bytes (+0.35%) +7 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 54300 bytes -14747 bytes (-21.36%)
RAR (proprietary) RAR rar a -m5 -md64m -mc63:128t -mt1 60342 bytes -8705 bytes (-12.61%)
LZMA2 (Wikipedia) xz xz -9 61184 bytes -7863 bytes (-11.39%)
Brotli (Wikipedia) brotli brotli -q 11 61322 bytes -7725 bytes (-11.19%)
PPMd (Wikipedia) 7zip 7za a -mx=9 -m0=ppmd 62315 bytes -6732 bytes (-9.75%)
ZSTD (Wikipedia) zstd zstd -19 66720 bytes -2327 bytes (-3.37%)
Burrows-Wheeler transform (Wikipedia) bzip2 bzip2 -9 67815 bytes -1232 bytes (-1.78%)

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