Choose a version:
13% The original file has 498897 bytes (487.2k) and is available from the project website.
There you can find the official minified version, too, which brings down the size to 65772 bytes (64.2k, 13%).

After GZIP compression these minified files vary in size:
Boot
  25776 bytes (25.2k)
CDN, direct link
cdnjs
  22845 bytes (22.3k)
CDN, direct link
cdnhttps
  22677 bytes (22.1k)
CDN, direct link
gzip -6 (default)
  21843 bytes (21.3k)
local copy
unpkg
  21828 bytes (21.3k)
CDN, direct link
gzip -9
  21780 bytes (21.3k)
local copy
jsdelivr
  21778 bytes (21.3k)
CDN, direct link
libdeflate -12
  21097 bytes (20.6k)
local copy
7zip -mx=9 -tgzip
  21059 bytes (20.6k)
local copy
kzip -s0 -rn -b4
  21007 bytes (20.5k)
local copy
pigz -11 -n
  20986 bytes (20.5k)
local copy
Zopfli
  20926 bytes (20.4k)
local copy

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

You will automatically get the smallest lodash 4.7.0 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 852 bytes by using my lodash 4.7.0 Zopfli version instead of the best available CDN (4.07% smaller than jsdelivr, 20926 vs. 21778 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 --i100000 --mb8 --mls8192 --bsr20 --lazy --ohh

(found April 13, 2016)
Description Value Parameter
iterations 100000  --i100000
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

Verify file integrity

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

MD5:
curl --silent --compressed https://raw.githubusercontent.com/lodash/lodash/4.7.0/dist/lodash.min.js --location | md5sum
7b4b76e0e423c7e14044e7be955efabd  -
curl --silent --compressed http://minime.stephan-brumme.com/files/lodash/lodash-4.7.0.min.zopfli.js.gz | md5sum
7b4b76e0e423c7e14044e7be955efabd  -

SHA1:
curl --silent --compressed https://raw.githubusercontent.com/lodash/lodash/4.7.0/dist/lodash.min.js --location | sha1sum
d1291a544f444ef4d09bd4e93725ce9c6f4264f7  -
curl --silent --compressed http://minime.stephan-brumme.com/files/lodash/lodash-4.7.0.min.zopfli.js.gz | sha1sum
d1291a544f444ef4d09bd4e93725ce9c6f4264f7  -

These CDNs send you the original file:
CDN Size (compressed) MD5 (uncompressed) Timestamp
unpkg 21828 bytes 7b4b76e0e423c7e14044e7be955efabd July 11, 2016 @ 16:46
jsdelivr 21778 bytes 7b4b76e0e423c7e14044e7be955efabd (invalid)

And some CDNs send you a different file:
CDN Size (compressed) MD5 (uncompressed) Comment / Diff Timestamp
Boot 25776 bytes 919dc0972d0dbfcfe81b0e82a17564de < /**
< * @license
< * lodash 4.7.0 (Custom Build) lodash.com/license | Unders [...]
< * Build: `lodash -o ./dist/lodash.js`
< */
< ;(function(){function t(t,n){return t.set(n[0],n[1]),t}fun [...]
< return true}function i(t,n){for(var r=-1,e=t.length,u=0,o= [...]
< var u=t.length;for(e&&u&&(r=t[--u]);u--;)r=n(r,t[u],u,t);r [...]
< return-1}function y(t,n,r,e){--r;for(var u=t.length;++r<u; [...]
< })}function O(t){return function(n){return t(n)}}function [...]
[...]
May 4, 2016 @ 10:40
cdnjs 22845 bytes 0574ef6ff97d31e219f875806384d2c0 < /**
< * @license
< * lodash 4.7.0 (Custom Build) lodash.com/license | Unders [...]
< * Build: `lodash -o ./dist/lodash.js`
< */
< ;(function(){function t(t,n){return t.set(n[0],n[1]),t}fun [...]
< return true}function i(t,n){for(var r=-1,e=t.length,u=0,o= [...]
< var u=t.length;for(e&&u&&(r=t[--u]);u--;)r=n(r,t[u],u,t);r [...]
< return-1}function y(t,n,r,e){--r;for(var u=t.length;++r<u; [...]
< })}function O(t){return function(n){return t(n)}}function [...]
[...]
(invalid)
cdnhttps 22677 bytes 919dc0972d0dbfcfe81b0e82a17564de < /**
< * @license
< * lodash 4.7.0 (Custom Build) lodash.com/license | Unders [...]
< * Build: `lodash -o ./dist/lodash.js`
< */
< ;(function(){function t(t,n){return t.set(n[0],n[1]),t}fun [...]
< return true}function i(t,n){for(var r=-1,e=t.length,u=0,o= [...]
< var u=t.length;for(e&&u&&(r=t[--u]);u--;)r=n(r,t[u],u,t);r [...]
< return-1}function y(t,n,r,e){--r;for(var u=t.length;++r<u; [...]
< })}function O(t){return function(n){return t(n)}}function [...]
[...]
November 22, 2016 @ 16:35

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

Other Versions

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

4.17.4, 4.17.3, 4.17.2, 4.17.1, 4.17.0, 4.16.6, 4.16.5, 4.16.4, 4.16.3, 4.16.2, 4.16.1, 4.16.0, 4.15.0, 4.14.2, 4.14.1, 4.14.0, 4.13.1, 4.13.0, 4.12.0, 4.11.2, 4.11.1, 4.11.0, 4.10.0,
4.9.0, 4.8.2, 4.8.1, 4.8.0, 4.7.0, 4.6.1, 4.6.0, 4.5.1, 4.5.0, 4.4.0, 4.3.0, 4.2.1, 4.2.0, 4.1.0, 4.0.1, 4.0.0

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

Changelog

Best Zopfli parameters so far:
Size Improvement Parameters Found
20926 bytes -2 bytes zopfli --i100000 --mls8192 --bsr20 --lazy --ohh April 13, 2016 @ 17:30
20928 bytes -1 byte zopfli --i10000 --mls8192 --bsr20 --lazy --ohh April 13, 2016 @ 09:39
20929 bytes -4 bytes zopfli --i10000 --mls8192 --bsr13 --lazy --ohh April 12, 2016 @ 13:29
20933 bytes -1 byte zopfli --i1000 --mls8192 --bsr8 --lazy --ohh April 12, 2016 @ 09:55
20934 bytes -1 byte zopfli --i1000 --mls4096 --bsr15 --lazy --ohh April 12, 2016 @ 09:23
20935 bytes -5 bytes zopfli --i1000 --mls8 --bsr8 --lazy --ohh April 12, 2016 @ 09:23
20940 bytes zopfli --i100 --mls8192 --bsr22 --lazy --ohh April 12, 2016 @ 02:47

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

Most recent activity on November 22, 2016 @ 16:35.

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 or 100,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
20961 20967 20965 20969 20981 20983 20981 20987 20988 20978 20948 20938 20954 20974 20973
20947 20933 20938 20939 20934 20937 20934 20933 20942 20951 20945 20953 20937 20961 20952
20954 20954 20943 20936 20943 20945 20935 20934 20956 20951 20949 20945 20943 20955 20964
20931 20945 20939 20946 20938 20937 20951 20951 20963 20931 20951 20935 20936 20936 20936
20931 20933 20930 20934 20933 20936 20950 20950 20931 20953 20942 20933 20931 20946 20957
20937 20935 20937 20969 20934 20943 20931 20965 20951 20970 20939 20938 20952 20952 20939
20935 20941 20936 20933 20939 20934 20935 20933 20933 20933 20947 20954 20951 20938 20944
20934 20934 20943 20935 20952 20940 20931 20949 20950 20930 20946 20935 20930 20934 20945
20952 20945 20939 20943 20936 20935 20950 20950 20951 20950 20939 20932 20932 20941 20943
20946 20945 20944 20938 20940 20935 20934 20950 20957 20938 20951 20937 20929 20947 20940
20935 20939 20943 20946 20938 20936 20950 20953 20941 20931 20934 20937 20953 20948 20949
20941 20945 20945 20937 20938 20951 20935 20949 20962 20944 20951 20931 20935 20937 20946
20935 20955 20945 20935 20936 20941 20950 20930 20949 20931 20942 20936 20942 20948 20939
20935 20946 20938 20947 20937 20933 20949 20951 20950 20951 20942 20954 20933 20946 20946
20933 20947 20934 20945 20934 20933 20950 20952 20950 20950 20949 20939 20935 20939 20955
20935 20936 20938 20934 20939 20942 20949 20951 20958 20937 20944 20950 20933 20944 20944
20932 20935 20936 20933 20935 20934 20951 20950 20950 20939 20944 20939 20926 20939 20939
20936 20934 20937 20935 20936 20939 20936 20934 20950 20941 20937 20934 20934 20943 20935
20934 20935 20937 20935 20936 20938 20950 20950 20962 20951 20943 20939 20931 20946 20950
20940 20935 20937 20935 20935 20944 20950 20950 20950 20951 20950 20950 20932 20947 20947
20944 20946 20946 20947 20937 20938 20950 20950 20950 20950 20953 20938 20952 20947 20943
20935 20935 20936 20937 20935 20940 20950 20950 20950 20951 20943 20935 20936 20941 20944
20934 20935 20946 20937 20934 20944 20932 20932 20960 20949 20953 20933 20936 20943 20939

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 20940 bytes 100%
1,000 20933 bytes -7 bytes 100%
10,000 20928 bytes -5 bytes 100%
100,000 20926 bytes -2 bytes 0.29%
1,000,000
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
21016 bytes +90 bytes (+0.43%) +9 bytes
21088 bytes +162 bytes (+0.77%) +81 bytes
21008 bytes +82 bytes (+0.39%) +1 byte
21016 bytes +90 bytes (+0.43%) +9 bytes
21007 bytes +81 bytes (+0.39%)
21019 bytes +93 bytes (+0.44%) +12 bytes
21043 bytes +117 bytes (+0.56%) +36 bytes
21066 bytes +140 bytes (+0.67%) +59 bytes
21091 bytes +165 bytes (+0.79%) +84 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 17763 bytes -3163 bytes (-15.12%)
RAR (proprietary) RAR rar a -m5 -md64m -mc63:128t -mt1 18073 bytes -2853 bytes (-13.63%)
PPMd (Wikipedia) 7zip 7za a -mx=9 -m0=ppmd 18380 bytes -2546 bytes (-12.17%)
Brotli (Wikipedia) brotli brotli -q 11 19630 bytes -1296 bytes (-6.19%)
LZMA2 (Wikipedia) xz xz -9 20196 bytes -730 bytes (-3.49%)
Burrows-Wheeler transform (Wikipedia) bzip2 bzip2 -9 20277 bytes -649 bytes (-3.10%)
ZSTD (Wikipedia) zstd zstd -19 20813 bytes -113 bytes (-0.54%)

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