Choose a version:
28% The original file has 276794 bytes (270.3k) and is available from the project website.
There you can find the official minified version, too, which brings down the size to 78798 bytes (77.0k, 28%).

After GZIP compression these minified files vary in size:
gzip -6 (default)
  26518 bytes (25.9k)
local copy
gzip -9
  26496 bytes (25.9k)
local copy
Sina
  26464 bytes (25.8k)
CDN
7zip -mx=9 -tgzip
  25368 bytes (24.8k)
local copy
kzip -s0 -rn -b7
  25321 bytes (24.7k)
local copy
libdeflate -12
  25312 bytes (24.7k)
local copy
zultra
  25304 bytes (24.7k)
local copy
pigz -11 -n
  25284 bytes (24.7k)
local copy
Zopfli
  25187 bytes (24.6k)
local copy

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

You will automatically get the smallest Dojo 1.2.2 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 1277 bytes by using my Dojo 1.2.2 Zopfli version instead of the best available CDN (5.07% smaller than Sina, 25187 vs. 26464 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 --bsr16 --lazy --ohh

(found March 2, 2020)
Description Value Parameter
iterations 1000000  --i1000000
maximum blocks 8  --mb8
maximum length score 64  --mls64
block splitting recursion 16  --bsr16
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://download.dojotoolkit.org/release-1.2.2/dojo.js --location | md5sum
50c6c42ae9fb8e640872d3100517c0a5  -
curl --silent --compressed https://minime.stephan-brumme.com/files/dojo/dojo-1.2.2.min.zopfli.js.gz | md5sum
50c6c42ae9fb8e640872d3100517c0a5  -

SHA1:
curl --silent --compressed https://download.dojotoolkit.org/release-1.2.2/dojo.js --location | sha1sum
674c70f0deaa5ed29a77c5bbc728cf9ca01084f0  -
curl --silent --compressed https://minime.stephan-brumme.com/files/dojo/dojo-1.2.2.min.zopfli.js.gz | sha1sum
674c70f0deaa5ed29a77c5bbc728cf9ca01084f0  -

All listed CDNs deliver identical contents:
CDN Size (compressed) MD5 (uncompressed) Timestamp
Sina 26464 bytes 50c6c42ae9fb8e640872d3100517c0a5 April 25, 2019 @ 14:07

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

Other Versions

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

1.17.3, 1.17.2, 1.17.1, 1.17.0,
1.16.5, 1.16.4, 1.16.3, 1.16.2, 1.16.1, 1.16.0,
1.15.6, 1.15.5, 1.15.4, 1.15.3, 1.15.2, 1.15.1, 1.15.0,
1.14.9, 1.14.8, 1.14.7, 1.14.6, 1.14.5, 1.14.4, 1.14.3, 1.14.2, 1.14.1, 1.14.0,
1.13.10, 1.13.9, 1.13.8, 1.13.7, 1.13.6, 1.13.5, 1.13.4, 1.13.3, 1.13.2, 1.13.1, 1.13.0,
1.12.11, 1.12.10, 1.12.9, 1.12.8, 1.12.7, 1.12.6, 1.12.5, 1.12.4, 1.12.3, 1.12.2, 1.12.1,
1.11.13, 1.11.12, 1.11.11, 1.11.10, 1.11.9, 1.11.8, 1.11.7, 1.11.6, 1.11.5, 1.11.4, 1.11.3, 1.11.2, 1.11.1, 1.11.0,
1.10.10, 1.10.9, 1.10.8, 1.10.7, 1.10.6, 1.10.5, 1.10.4, 1.10.3, 1.10.2, 1.10.1, 1.10.0,
1.9.11, 1.9.10, 1.9.9, 1.9.8, 1.9.7, 1.9.6, 1.9.5, 1.9.4, 1.9.3, 1.9.2, 1.9.1, 1.9.0,
1.8.14, 1.8.13, 1.8.12, 1.8.11, 1.8.10, 1.8.9, 1.8.8, 1.8.7, 1.8.6, 1.8.5, 1.8.4, 1.8.3, 1.8.2, 1.8.1, 1.8.0,
1.7.12, 1.7.11, 1.7.10, 1.7.9, 1.7.8, 1.7.7, 1.7.6, 1.7.5, 1.7.4, 1.7.3, 1.7.2, 1.7.1, 1.7.0,
1.6.5, 1.6.4, 1.6.3, 1.6.2, 1.6.1, 1.6.0,
1.5.6, 1.5.5, 1.5.4, 1.5.3, 1.5.2, 1.5.1, 1.5.0,
1.4.8, 1.4.7, 1.4.6, 1.4.5, 1.4.4, 1.4.3, 1.4.2, 1.4.1, 1.4.0,
1.3.3, 1.3.2, 1.3.1, 1.3.0,
1.2.3, 1.2.2

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

Changelog

Best Zopfli parameters so far:
Size Improvement Parameters Found
25187 bytes -3 bytes zopfli --i1000000 --mls64 --bsr16 --lazy --ohh March 2, 2020 @ 14:53
25190 bytes -3 bytes zopfli --i100000 --mls64 --bsr16 --lazy --ohh January 28, 2020 @ 18:20
25193 bytes -4 bytes zopfli --i10000 --mls64 --bsr16 --lazy --ohh January 28, 2020 @ 17:40
25197 bytes -1 byte zopfli --i1000 --mls64 --bsr16 --lazy --ohh January 28, 2020 @ 16:52
25198 bytes -4 bytes zopfli --i1000 --mls8192 --bsr14 --lazy --ohh January 28, 2020 @ 14:00
25202 bytes zopfli --i100 --mls64 --bsr16 --lazy --ohh January 28, 2020 @ 13:40

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

Most recent activity on March 16, 2022 @ 09:04.

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
25221 25217 25240 25230 25274 25233 25294 25270 25270 25273 25271 25281 25248 25277 25265
25242 25237 25241 25242 25245 25273 25268 25264 25262 25265 25265 25266 25223 25278 25276
25228 25249 25242 25225 25283 25268 25290 25265 25273 25269 25271 25271 25276 25268 25272
25209 25240 25235 25247 25289 25285 25277 25264 25277 25266 25267 25272 25277 25276 25271
25216 25236 25235 25246 25239 25272 25291 25265 25273 25267 25270 25270 25276 25270 25268
25241 25235 25216 25218 25285 25285 25290 25264 25265 25269 25266 25270 25275 25270 25268
25248 25235 25232 25242 25238 25287 25284 25265 25276 25264 25266 25267 25275 25281 25272
25225 25239 25216 25220 25247 25191 25283 25266 25264 25267 25267 25268 25219 25271 25272
25209 25235 25219 25219 25239 25187 25283 25284 25266 25265 25265 25266 25216 25279 25270
25229 25219 25217 25223 25239 25234 25283 25265 25281 25267 25264 25267 25286 25270 25271
25247 25230 25231 25237 25234 25279 25281 25265 25265 25268 25267 25269 25194 25278 25265
25237 25238 25241 25237 25233 25193 25280 25265 25284 25266 25268 25269 25273 25270 25271
25224 25231 25237 25219 25236 25187 25281 25265 25267 25270 25275 25274 25221 25270 25271
25252 25222 25243 25221 25216 25278 25285 25265 25265 25263 25270 25272 25275 25276 25272
25249 25236 25221 25230 25244 25266 25284 25267 25268 25267 25266 25269 25276 25270 25271
25235 25235 25243 25243 25242 25287 25290 25285 25290 25269 25268 25270 25276 25271 25272
25237 25229 25236 25247 25239 25287 25291 25263 25273 25267 25270 25276 25198 25271 25272
25226 25235 25217 25273 25266 25276 25264 25265 25265 25263 25269 25269 25276 25275 25273
25234 25240 25221 25243 25239 25285 25282 25263 25264 25268 25266 25265 25278 25278 25269
25237 25228 25241 25247 25224 25281 25280 25264 25267 25267 25270 25268 25277 25269 25271
25234 25233 25233 25235 25239 25193 25277 25265 25265 25264 25266 25268 25276 25271 25268
25241 25247 25218 25241 25217 25279 25284 25265 25263 25265 25268 25266 25276 25269 25271
25223 25220 25237 25241 25239 25279 25277 25220 25266 25264 25266 25267 25238 25271 25270

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 25202 bytes 100%
1,000 25197 bytes -5 bytes 100%
10,000 25192 bytes -5 bytes 100%
100,000 25190 bytes -2 bytes 0.87%
1,000,000 25187 bytes -3 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
25327 bytes +140 bytes (+0.56%) +6 bytes
25326 bytes +139 bytes (+0.55%) +5 bytes
25341 bytes +154 bytes (+0.61%) +20 bytes
25321 bytes +134 bytes (+0.53%)
25353 bytes +166 bytes (+0.66%) +32 bytes
25339 bytes +152 bytes (+0.60%) +18 bytes
25324 bytes +137 bytes (+0.54%) +3 bytes
25321 bytes +134 bytes (+0.53%)
25359 bytes +172 bytes (+0.68%) +38 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 20492 bytes -4695 bytes (-18.64%)
RAR (proprietary) RAR rar a -m5 -md64m -mc63:128t -mt1 22442 bytes -2745 bytes (-10.90%)
PPMd (Wikipedia) 7zip 7za a -mx=9 -m0=ppmd 23339 bytes -1848 bytes (-7.34%)
Brotli (Wikipedia) brotli brotli -q 11 23405 bytes -1782 bytes (-7.08%)
LZMA2 (Wikipedia) xz xz -9 24312 bytes -875 bytes (-3.47%)
Zstandard (Wikipedia) zstd zstd -19 24796 bytes -391 bytes (-1.55%)
Burrows-Wheeler transform (Wikipedia) bzip2 bzip2 -9 25060 bytes -127 bytes (-0.50%)

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

All trademarks are property of their respective owners. You know, the boring legal stuff.