I'm doing about 250k of pop traffic a day in Brazil and Amazon Cloudfront is getting expensive and really chewing into my Profits.
I was wondering if anyone had any ideas for cheaper hosting options which will have similar or better performance?
At the moment thinking of testing
* Reducing File Size (I get charged by use of bandwidth)
* Cloudflare CDN
* Find a Cheap Fast Server located in Brazil of nearby
I was wondering if anyone
1). Have any other ideas?
2). Know of any other CDNs that cover South America that are cheaper than Amazon?
3). Know of any good cheap fast server I could try that are located near Brazil (closest Vultr server is Miami)
thanks!
I would start maybe looking for a local VPS hosting in this location.
Also make sure you request javascript/css libraries from external CDN's (jquery, bootstrap, sweetalert etc.)
Compress everything for sure: html code, js, css, images.
Here I did image compressors comparison in the past: 5 Image Compressors Side by Side Comparison (2017)
For CSS you can use https://cssminifier.com/ and https://javascript-minifier.com/ for JS.
Also make sure you remove unnecessary CSS that is not used in your code, you can do it with UnCSS https://uncss-online.com/.
Hope it helps to save you some extra $'s.
P.S. Sometimes people rip landers and leave links to your CDN, this can make costs higher too.
Thanks erikgyepes!
Had a look at my file size - and it was 190kb!
I'd put all the images in base64 and put it into the file.
So I'm running 4 tests at the moment to see if there is a difference in performance
Test 1: Current 190kb file (1 html and 0 image files) - It is a single html with all images inside file in base64
Test 2: Got it down to 112kb (1 html and 7 image files) --> Took out base64 images & made them seperate files (and yes the images had been compressed)
Test 3: Got it down to 98kb (1 html and 7 image files) --> Cropped and reduce the files of some of the images in test 2
Test 4: Got it down to 78kb (1 html and 7 image files) --> Used the image optimizer tool from xat (paid product) to reduce image size even more than kraken or compressor.io (reduces picture quality a little but I think it is worth testing).
Will post results once I see if performance is better (or worse or just comparable)
Did you enable Gzip?
I found this tutorial quite handy: https://www.youtube.com/watch?v=Bl9EXnQR5Eo
Make sure to:
1. Enable compression
2. Add that line of code to your bucket
Hi Eurosen,
Thanks!
Will put it onto list of thing to test.
BTW, have you tested:
1). Pages with gzip and compression
versus
2). Pages without gzip and compression
to see if there is a performance difference?
Give it a try and see the difference.
I saw a huge difference in performance and my aws bill.
Gzip aside (this is a no-brainer), if your traffic costs and revenues are very low vs the traffic volume to the point that CDN costs are impacting profitability to a great extent, just switch to Cloudflare.
Their free plan is fine and has no charge for bandwidth. So you'd go from $x CDN overhead to $0 overhead. This is another no-brainer in my opinion.
Definitely give cloudflare a go. Spending $600/month on a CDN if I'm reading your other post right is just nuts.
You'll still need to host your index/lander.html files though somewhere though. In the past I used Amazon S3 nowadays I just use netlify.
Additionally, if you:
1) don't need to track/append things to the URL or your landing page, eg placements, tracking ids, etc (mylander.com?placement=cnn.com) or
2) have a tracker that can omit parameters from the landing page url (FunnelFlux can do this,
then you can actually serve the root index.html file as well from cloudflare via their page caching rules, making everything served from cloudflare and for free.
Otherwise each unique url request made, eg example.com & example.com?trackingid=123 count as a unique request so each new one will bypass cloudflare to go to the origin, effectively disabling that .html caching feature unless you want to pay the $200/month I think it is to get that feature.
Hi Guys,
************
[1] GZIP -
***********
I like testing things to make sure they don't reduce ROI badly - so I'm testing gzip before I roll it out
I know it 'should' work better, but I'm wary of the stuff 'I don't know I don't know' which might end up actually reducing ROI for whatever reason.
So I'll test it before I roll it out.
Testing Method
- I setup a gzip version of the file using 7-Zip (got the html file from 190kb down to 97kb)
- Loaded it into Amazon S3 and set the Meta-Data to (Content Encoding --> gzip) for that file
- Am testing it against the current non-gzipped version
**********************
[2] Cloudflare
************************
Fu##@ - sorry just had to get it out of my system - lol
Thanks thedudeabides for helping me figure something out.
I started testing cloudflare yesterday but hardly anything was caching!
Could not figure it out!
I setup pages rules so it would cache everything (even HTML)
BUT, I forgot that
What I am going to try
[1] I'm going to change my PAGE RULES in Cloudflare to 'ignore query' string instead of 'standard' when it caches HTML
I don't think this will work since
* 'ignore query' is only supposed to work for certain static file extensions and html is not one of them
* I'm not seeing CF-Cache-Status in the header when I tested it out
But I'll check in a few hours to see if more is being cached.


[2] Stop serving the Popup as 1 file (HTML with all images inside it as BASE64) and instead make it separate files (1 HTML 6 image files) with those images served by Cloudflare
NB: I've seen a drop in ROI of up to 30% when I don't put the popup all in 1 html file in cloudfront but will see what happens on cloudflare.
IF THOSE DO NOT WORK
[1] I'll look at trying FunnelFlux with Cloudflare.
-- I did not realize funnelflux had a managed solution!
[2] OR just find a local server near brazil (I have a friend who uses Vultr out of Dallas for S. America .. but not sure if there is something closer?)
Cloudflare automatically g-zips files for you, actually something better called brotli.
I don't recall where that specific index caching feature I mentioned earlier is in their paid plans, just that I remember looking into it and it wasn't possible on the free one with unique url requests every time.
But regardless I definitely wouldn't recommend paying $200/month for a feature to help get an edge with a campaign that's a $60/day profit. You'd need a solid ROI increase just to break-even and I don't see that happening coming from already being on a decent CDN.
You'd better off taking that money and paying for custom creatives, angles, landers, testing new campaigns, etc. Just my 2c.
Hi Everyone,
Just thought I'd let you know how the test went.
Test 1: Current 190kb file (1 html and 0 image files) - It is a single html with all 7 images inside file in base64
Test 2: Used GZIP --> Got it down to 98kb (1 html and 0 image files)
Test 3: Shrunk Images More and then GZIP --> Got it down to 62kb (1 html and 0 image files):
* I used the image optimizer tool from xat (paid product) to reduce image size even more than kraken or compressor.io (lets you custom reduce size of files but also reduces picture quality).
Test 4: Used CloudFlare (1 html and 7 image files) - Split the file up into the HTML and 7 images and used cloudflare. The HTML part of the file came down to 20kb
RESULTS
1. Test 2,3,4 beat Test1. No surprises there. Gzip beat ungzipped. And cloudflare beat ungzipped single file
2. Overall Profit (including cost of hosting) - Test 3 was best but not statistically significantly better than 4 (and beat Test 2 by about 85% certainty).
The difference in profit between using Cloudflare or just using Cloudfront was too small to be statistically significant.
So just stayed with Cloudfront, since I'm familiar with it.
3. Performance (i.e. CV%) - Test 2 and 3 beat Test 4 (see below). So Cloudfront did beat Cloudflare on pure performance.
Test 2,3 BEAT 4 in terms of performance but not profit.
The screenshot from
Test 2 gets charged by Amazon Hosting for 97kb download for every pop
Test 3 gets charged by Amazon Hosting for 63kb download for every pop
Test 4 gets charged by Amazon Hosting for 20kb download for every pop

This type of comparison is GOLD! Thanks so much Suneel for taking the trouble (and spending the cash!) and time, and to organize and presenting the results in such a systematic manner!
So basically the difference between cloudfront and cloudflare is not enough to affect profits in any significant way.
Now I know what to tell people when they ask "which one is best". Thank you so much!
Amy
Sent from my SM-G930W8 using STM Forums mobile app
Hi Amy,
Thanks!
[1] I will caution you that this was just done in one country, so I'm not sure it there is a major difference in other locations.
[2] Cloudflare actually beat Cloudfront if you did not use Base64 (i.e. if you had 1 HTML files and several image files on both cloudflare and cloudfront).
[3] My gut feel is that at higher CV%, Cloudfront will be better than Cloudflare - but we are talking possibly about a 5% difference in ROI.
So at the end of the day, difference between the
* Best cloudfront config (1 file with BASE64 images, GZIP) and
* Best cloudflare config (1 HTML file and several Image Files)
... could be between 0% to 5% of ROI depending on CV%. So really should not be something newbies focus on.
Which means people should really optimize other stuff (e.g. offers, traffic) and only start playing around with this if they
i). Have already optimized offers and traffic
ii). Are doing more than 50,000/day pops (or when they reach the limit of the free bandwidth from their Host)
Hope that helps :-)
Great stuff Grofit, thanks for sharing your results 