Home > Paid Traffic Sources > POP / PPV / Redirect

Looking For Cheaper Option Than Amazon Cloudfront for Brazil (16)


01-08-2019 01:19 AM #1 grofit (AMC Alumnus)
Looking For Cheaper Option Than Amazon Cloudfront for Brazil

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!


01-08-2019 02:04 AM #2 erikgyepes (Moderator)

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.


01-09-2019 04:20 AM #3 grofit (AMC Alumnus)

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)


01-09-2019 05:21 AM #4 eurosen (AMC Alumnus)

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


01-09-2019 05:42 AM #5 grofit (AMC Alumnus)

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?


01-09-2019 08:05 AM #6 eurosen (AMC Alumnus)

Give it a try and see the difference.

I saw a huge difference in performance and my aws bill.


01-09-2019 06:57 PM #7 zeno (Administrator)

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.


01-09-2019 11:04 PM #8 thedudeabides (Moderator)

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, Voluum & Binom don't)

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.


01-10-2019 10:08 AM #9 grofit (AMC Alumnus)

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 Voluum adds a unique identifier to each page!

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.

Click image for larger version. 

Name:	Screenshot_2.jpg 
Views:	10 
Size:	101.0 KB 
ID:	20311

Click image for larger version. 

Name:	Screenshot_3.jpg 
Views:	10 
Size:	93.2 KB 
ID:	20312


[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?)


01-10-2019 10:41 AM #10 grofit (AMC Alumnus)

Quote Originally Posted by thedudeabides View Post
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.
I could not find that feature (i.e. enabling html caching) for cloudflare - do you have a link to it?
I'm looking at it as an option :-)


01-10-2019 09:37 PM #11 thedudeabides (Moderator)

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.


01-26-2019 04:32 AM #12 grofit (AMC Alumnus)

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 Voluum below does not take into account the cost of hosting.

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

Click image for larger version. 

Name:	Screenshot_1.jpg 
Views:	40 
Size:	43.3 KB 
ID:	20507


01-27-2019 08:35 AM #13 vortex (Senior Moderator)

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


01-27-2019 11:21 PM #14 grofit (AMC Alumnus)

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 :-)


01-28-2019 10:54 AM #15 matuloo (Legendary Moderator)

Great stuff Grofit, thanks for sharing your results


03-17-2019 08:59 AM #16 bluemarble (Member)

Quote Originally Posted by grofit View Post
[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).
I suspect what's happening is that due to the query strings. As mentioned, Cloudflare considers each call to index.html as unique because of the query strings. When you include images in index.html, it just increases the size of index.html without any caching.

When you separate out images, Cloudflare is able to cache the images. And of course, index.html will be smaller.


Home > Paid Traffic Sources > POP / PPV / Redirect