Document complete in under half a second, with TTFB of 0.391s and document complete 0.518s

These look pretty respectable, but now compare with an EC2 instance (t1.large linux) using Google Go language as a HTTP server

Document Complete

Fully Loaded

Load Time

First Byte

Start Render

DOM Elements

Time

Requests

Bytes In

Time

Requests

Bytes In

First View

0.342s

0.212s

0.000s

14

0.342s

1

1 KB

0.342s

1

1 KB

Repeat View

0.389s

0.224s

0.000s

14

0.389s

1

1 KB

0.389s

1

1 KB

Faster across the board - TTFB has halved to 0.212s and this is time saved off document complete and fully loaded. I was expecting that S3 would be very fast at serving static content, and its looks reasonable, but compared to this single server (large admittedly) its a fair % slower.

Now what happens with Google adverts? we get a similar google ads penalty to last time, 1.5s penalty on document complete and fully loaded:

Document Complete

Fully Loaded

Load Time

First Byte

Start Render

DOM Elements

Time

Requests

Bytes In

Time

Requests

Bytes In

First View

1.582s

0.283s

0.411s

175

1.582s

10

51 KB

1.582s

10

51 KB

Repeat View

1.184s

0.210s

0.523s

175

1.184s

2

6 KB

1.184s

2

6 KB

Whats hidden in these numbers is a little gem - the ~0.200s saved using the EC2 instance is still there, i.e. this performs ~0.200s faster than S3 even when using Google Ads.

So even if you have a very heavy page, and are using CDN or other techniques to speed things up, you really need to see if you can get your TTFB down - and that may mean looking at async HTTP servers such as Go or Node.js

Here is the Go code for this example (the HTML is literal using back-quotes `), based on one of the Go examples:

Note that the previous tests were rerun to ensure no significant variance in timings. The next set of test will be to see if we can keep sub-0.300s for template based content (as opposed to hard-coded HTML)