This is a big guide, prep your coffee
I wrote this for our FunnelFlux Pro customers, you can see the original here (it may be more readable there).
My goal was to give people a cost-effective and streamlined setup for running a lot of landers and automating their FunnelFlux tracking. But, you could use this setup for anything and any tracker.
It may seem complex but its actually quite easy to set up even for newbies, and I have tried to make it comprehensive to the point an absolute beginner could still get it live and working quite quickly.
Anyway, dumping my guide below!
-----------------------------------------
Chances are you are in need of landing page hosting.
If you need something simple and visual to get started, check out Landerlab. If you are looking for something free or more technical (i.e. getting into the code), read on.
Unless you're using something like Leadpages, Wix, Wordpress etc., you'll likely be using static landers -- that is, landers composed of HTML, CSS and JS files.
These types of files are all "client-side" and can be cached by CDNs and delivered quickly, so are great for affiliate marketing landing pages used in campaigns across the globe.
...but, they can be more annoying to manage than a simple visual editor on some platform.
If you're an affiliate marketer and you want a streamlined setup that:
...then continue reading and I'll show you how to get it set up from A-to-Z with GitHub, Netlify, Cloudflare, and automated tracking with FunnelFlux Pro.
This setup will make it simple to manage 100's of landers, you can replicate it across unlimited domains, you don't have to wait for slow FTP, and you'll get automated minification, image recompression and ridiculous fast page delivery.
This guide is designed for newbies and goes through things step-by-step, hence the length of it (if you're already quick technically skilled, just skim).
Getting Started
Before we begin, you'll need several accounts:
If you don't have any of these, go and sign up for an account now. They are all free.
Get a basic Git repository set up
GitHub is a version control system. It's one of several that developers use to collaborate on software development and commit code. It's also very useful for basic website creation, as it lets you keep track of changes.
Firstly, go set up a GitHub account.
Once logged in, on your dashboard you should be able to create a new repository:
Name the repository something sensible like "my-affiliate-landers". Choose private. I would tick to add a readme, a .gitignore and a license, just to populate some "stuff" in the repository. It doesn't matter what you pick for the ignore/license.
You're going to need a different repository for different domains you use (with separate content), so the domain itself might be a good name too -- and I would recommend this if you decide to use this Netlify approach long term.
Now, click create repository.
Now that your repository is created, we'll need a way to access it remotely. For this we want a desktop application. If you already have one you like, use that, otherwise go download GitHub Desktop - GitHub Desktop
Once that is installed, we want to clone the repository into the app so we can edit everything on our PC directly.
Click the repository in GitHub (the site) to get to the base page of the repository. Then click the Code button > Open in GitHub desktop:
If you are on the page right after creating your repository, you can also do it directly from there:
This should trigger an alert to open in the GitHub desktop application. Click yes and it should open the app and a prompt like this:
Here, all you need to do is set the local path to some sensible directory. I would recommend making a clear folder in your working directory somewhere that's easy to access and not somewhere deep... e.g. C:\GitRepos\ is better than a folder buried in a dozen other folders (for various reasons).
So not like I have above where its inside some user account's documents folder.
Because this is going into a versioning system, don't worry about putting this inside something like Dropbox. There's no sense in double-syncing your content, and your Dropbox syncing could cause conflicts with GitHub, so avoid it.
Click CLONE and go. It should show a progress bar where it is cloning the repository, downloading objects, etc.
Once pulled, you'll notice in the top toolbar you have the current repository (use this pane for switching repositories), current branch, and an action button:
Here, just stick to master branch for now. We don't need to worry about a develop branch, pull requests and testing. For now lets keep it simple and have everything go live immediately -- you can make it nicer later.
And that's it! You now have a local Git "repo" set up where you can store all your landing page content and make changes.
Get your Cloudflare account ready
Not much to do here, but we need your domain and Cloudflare account to be ready.
Set one up, add your lander domain to it. If you're using track.domain.com with FunnelFlux and have your domains on domain.com, chances are you're already ready to go.
If not, you can check our domain setup guide and go through the basics of Cloudflare. You'll need to add the domain, then change the "nameservers" with your registrar (GoDaddy, Namecheap etc.) to point to Cloudflare.
Initial Netlify setup
Netlify is awesome -- what they provide for free is extremely cool.
Think of Netlify as a system that will automatically deploy your Github repo content to live hosting every time you commit changes. Its much easier and more automated than FTP and comes with a number of other advantages.
Head over to Netlify and sign up for a free account.
It will ask you various things as you sign up, e.g. a team, just whisk through it and get inside the dashboard. It should look something like this:
Feel free to browse around -- Plugins has a number of helpful plugins that can be used later, domains lets you move domains over to Netlify for automatic management, and so on. I would not recommend moving your domains over unless they are used only with Netlify, not with tracking or anything else.
So, let's get going -- click New site from Git.
Click GitHub as your continuous deployment provider:
A window will open asking you to authorise access to your GitHub account. Give it the permissions it needs. Once done, you can click a repository to add:
On clicking this it will ask you for final site settings -- just pick main branch and go, there's nothing further to change.
Once added it should redirect you to the site dashboard:
Once it fully deploys, you should have an app URL underneath the project name, e.g.
My Test Page
Click this and load it!
Did it work? Probably not, because we have nothing in our repository, right?
So, lets' put something in the repository first and commit our first change.
Go to the folder you set for your repository on your computer. Mine looks like this:
Create a new index.html file, open it in a text editor. Put the following code and save:
Now, when you save, the GitHub application is going to detect the file changes. Head back to GitHub desktop. You should see something like this:
When you make changes to your repository, you should see a list of changed files in the changes tab. If you click the files, it will show a change log with green for additions and red for deletions.
Now, we want to commit this change to the main branch (which we are already on).
To do that, type a title for the commit like "Initial index file" then click commit to main. Once you do this, your changes are "committed" locally, and you need to push them to the GitHub repository to formally save them.
Think of commits like draft saves, where you're saving various modifications and splitting them into chunks. Then when you're ready, you formally commit them to the repository, using one of these buttons:
Click it and go! Now, quickly switch to your Netlify dashboard.
It's integrated with GitHub so is listening for all commits. It will build very quickly on this occasion, so you might have already missed it. You should see your commit in the build list:
Now, load your app's URL again.
Hopefully... you should see your index file load with your "Nice, my first site via Netlify and GitHub!" content.
Well done, you've just created a full repository > live site integration with Netlify
Setting up a custom domain with Netlify
You're going to want to use a custom domain to point to your Netlify app as well as use Cloudflare for caching of content.
To do this, first get your domain added to Cloudflare. Now on your Netlify dashboard, go to domain settings:
Click add custom domain, then put the domain you want to use. You can put domain.com or sub.domain.com. Click verify.
When it asks if you are the owner, click yes.
It should redirect back to the custom domains section, now with your domain and a www subdomain added, and a check DNS configuration link.
Click this link to load the details we need:
We will use the alias approach. Head over to Cloudflare and add a new CNAME record that points your domain to the netlify app address they provide, like so:
For now, keep this in DNS only mode, i.e. gray cloud not orange cloud. We want to use orange cloud mode to use Cloudflare's CDN capabilities, but if we turn it on now it will interfere with Netlify verifying the domain.
Netlify will try to verify the domain automatically when you refresh the page, so there is nothing to do but wait until that "Check DNS configuration" alert goes away after a few minutes.
Lets also add a "www" record to satisfy them too. You can use the following approach (of course, use your domain name):
Once the check DNS alerts are gone, let's turn on Cloudflare's proxying to get full CDN capabilities.
For both the records you added, switch them to orange cloud mode:
Here you can see I have a "trk" subdomain record that points to FunnelFlux.
The easiest way to make this Cloudflare account work well for landing pages + tracking is to set account-level settings for the landing pages, then a single page rule for the trk subdomain that ensures it works well with FunnelFlux.
Head over to the page rules section. If you have a tracker record present, make sure you have a page rule following our guide that basically says don't cache anything, use flexible SSL, turn all security off, all performance off, etc.:
Now, lets go through the account settings and make sure we are maximising the performance enhancements for our landers:
Ok, that's all those settings sorted -- you probably didn't have to change much, but I wanted to be thorough.
Now, test it!
Our goal was to use a custom domain and SSL -- so test it!
Load your custom domain, e.g. My Test Page
Hopefully you'll see your HTML page and message and notice that the URL should redirect to HTTPS and show that its secure, since we set up automatic HTTPS rewrites for the domain:
I wrote this for our FunnelFlux Pro customers, you can see the original here (it may be more readable there).
My goal was to give people a cost-effective and streamlined setup for running a lot of landers and automating their FunnelFlux tracking. But, you could use this setup for anything and any tracker.
It may seem complex but its actually quite easy to set up even for newbies, and I have tried to make it comprehensive to the point an absolute beginner could still get it live and working quite quickly.
Anyway, dumping my guide below!
-----------------------------------------
Chances are you are in need of landing page hosting.
If you need something simple and visual to get started, check out Landerlab. If you are looking for something free or more technical (i.e. getting into the code), read on.
Unless you're using something like Leadpages, Wix, Wordpress etc., you'll likely be using static landers -- that is, landers composed of HTML, CSS and JS files.
These types of files are all "client-side" and can be cached by CDNs and delivered quickly, so are great for affiliate marketing landing pages used in campaigns across the globe.
...but, they can be more annoying to manage than a simple visual editor on some platform.
If you're an affiliate marketer and you want a streamlined setup that:
- Is free
- Is fast and has high performance delivery of pages
- Is quite automated and flexible
- And lets you automate part of your tracking setup...
...then continue reading and I'll show you how to get it set up from A-to-Z with GitHub, Netlify, Cloudflare, and automated tracking with FunnelFlux Pro.
This setup will make it simple to manage 100's of landers, you can replicate it across unlimited domains, you don't have to wait for slow FTP, and you'll get automated minification, image recompression and ridiculous fast page delivery.
This guide is designed for newbies and goes through things step-by-step, hence the length of it (if you're already quick technically skilled, just skim).
Getting Started
Before we begin, you'll need several accounts:
- A GitHub account
- A Netlify account
- A Cloudflare account and your lander domain added to it (chances are you'll be managing your tracking domain in the same place)
- A text editor like SublimeText, Notepad++, Atom, etc. My personal preference is Atom and I think it's default settings are better for a newbie to Git. So if you aren't particularly used to editing HTML, CSS etc., go get Atom too.
If you don't have any of these, go and sign up for an account now. They are all free.
Get a basic Git repository set up
GitHub is a version control system. It's one of several that developers use to collaborate on software development and commit code. It's also very useful for basic website creation, as it lets you keep track of changes.
Firstly, go set up a GitHub account.
Once logged in, on your dashboard you should be able to create a new repository:
Name the repository something sensible like "my-affiliate-landers". Choose private. I would tick to add a readme, a .gitignore and a license, just to populate some "stuff" in the repository. It doesn't matter what you pick for the ignore/license.
You're going to need a different repository for different domains you use (with separate content), so the domain itself might be a good name too -- and I would recommend this if you decide to use this Netlify approach long term.
Now, click create repository.
Now that your repository is created, we'll need a way to access it remotely. For this we want a desktop application. If you already have one you like, use that, otherwise go download GitHub Desktop - GitHub Desktop
Once that is installed, we want to clone the repository into the app so we can edit everything on our PC directly.
Click the repository in GitHub (the site) to get to the base page of the repository. Then click the Code button > Open in GitHub desktop:
If you are on the page right after creating your repository, you can also do it directly from there:
This should trigger an alert to open in the GitHub desktop application. Click yes and it should open the app and a prompt like this:
Here, all you need to do is set the local path to some sensible directory. I would recommend making a clear folder in your working directory somewhere that's easy to access and not somewhere deep... e.g. C:\GitRepos\ is better than a folder buried in a dozen other folders (for various reasons).
So not like I have above where its inside some user account's documents folder.
Because this is going into a versioning system, don't worry about putting this inside something like Dropbox. There's no sense in double-syncing your content, and your Dropbox syncing could cause conflicts with GitHub, so avoid it.
Click CLONE and go. It should show a progress bar where it is cloning the repository, downloading objects, etc.
Once pulled, you'll notice in the top toolbar you have the current repository (use this pane for switching repositories), current branch, and an action button:
Here, just stick to master branch for now. We don't need to worry about a develop branch, pull requests and testing. For now lets keep it simple and have everything go live immediately -- you can make it nicer later.
And that's it! You now have a local Git "repo" set up where you can store all your landing page content and make changes.
Get your Cloudflare account ready
Not much to do here, but we need your domain and Cloudflare account to be ready.
Set one up, add your lander domain to it. If you're using track.domain.com with FunnelFlux and have your domains on domain.com, chances are you're already ready to go.
If not, you can check our domain setup guide and go through the basics of Cloudflare. You'll need to add the domain, then change the "nameservers" with your registrar (GoDaddy, Namecheap etc.) to point to Cloudflare.
Initial Netlify setup
Netlify is awesome -- what they provide for free is extremely cool.
Think of Netlify as a system that will automatically deploy your Github repo content to live hosting every time you commit changes. Its much easier and more automated than FTP and comes with a number of other advantages.
Head over to Netlify and sign up for a free account.
It will ask you various things as you sign up, e.g. a team, just whisk through it and get inside the dashboard. It should look something like this:
Feel free to browse around -- Plugins has a number of helpful plugins that can be used later, domains lets you move domains over to Netlify for automatic management, and so on. I would not recommend moving your domains over unless they are used only with Netlify, not with tracking or anything else.
So, let's get going -- click New site from Git.
Click GitHub as your continuous deployment provider:
A window will open asking you to authorise access to your GitHub account. Give it the permissions it needs. Once done, you can click a repository to add:
On clicking this it will ask you for final site settings -- just pick main branch and go, there's nothing further to change.
Once added it should redirect you to the site dashboard:
Once it fully deploys, you should have an app URL underneath the project name, e.g.
My Test Page
Click this and load it!
Did it work? Probably not, because we have nothing in our repository, right?
So, lets' put something in the repository first and commit our first change.
Go to the folder you set for your repository on your computer. Mine looks like this:
Create a new index.html file, open it in a text editor. Put the following code and save:
Code:
<!DOCTYPE html>
<html>
<head>
<title>My Test Page</title>
</head>
<body>
<p>Nice, my first site via Netlify and GitHub!</p>
</body>
</html>
Now, when you save, the GitHub application is going to detect the file changes. Head back to GitHub desktop. You should see something like this:
When you make changes to your repository, you should see a list of changed files in the changes tab. If you click the files, it will show a change log with green for additions and red for deletions.
Now, we want to commit this change to the main branch (which we are already on).
To do that, type a title for the commit like "Initial index file" then click commit to main. Once you do this, your changes are "committed" locally, and you need to push them to the GitHub repository to formally save them.
Think of commits like draft saves, where you're saving various modifications and splitting them into chunks. Then when you're ready, you formally commit them to the repository, using one of these buttons:
Click it and go! Now, quickly switch to your Netlify dashboard.
It's integrated with GitHub so is listening for all commits. It will build very quickly on this occasion, so you might have already missed it. You should see your commit in the build list:
Now, load your app's URL again.
Hopefully... you should see your index file load with your "Nice, my first site via Netlify and GitHub!" content.
Well done, you've just created a full repository > live site integration with Netlify
Setting up a custom domain with Netlify
You're going to want to use a custom domain to point to your Netlify app as well as use Cloudflare for caching of content.
To do this, first get your domain added to Cloudflare. Now on your Netlify dashboard, go to domain settings:
Click add custom domain, then put the domain you want to use. You can put domain.com or sub.domain.com. Click verify.
When it asks if you are the owner, click yes.
It should redirect back to the custom domains section, now with your domain and a www subdomain added, and a check DNS configuration link.
Click this link to load the details we need:
We will use the alias approach. Head over to Cloudflare and add a new CNAME record that points your domain to the netlify app address they provide, like so:
For now, keep this in DNS only mode, i.e. gray cloud not orange cloud. We want to use orange cloud mode to use Cloudflare's CDN capabilities, but if we turn it on now it will interfere with Netlify verifying the domain.
Netlify will try to verify the domain automatically when you refresh the page, so there is nothing to do but wait until that "Check DNS configuration" alert goes away after a few minutes.
Lets also add a "www" record to satisfy them too. You can use the following approach (of course, use your domain name):
Once the check DNS alerts are gone, let's turn on Cloudflare's proxying to get full CDN capabilities.
For both the records you added, switch them to orange cloud mode:
Here you can see I have a "trk" subdomain record that points to FunnelFlux.
The easiest way to make this Cloudflare account work well for landing pages + tracking is to set account-level settings for the landing pages, then a single page rule for the trk subdomain that ensures it works well with FunnelFlux.
Head over to the page rules section. If you have a tracker record present, make sure you have a page rule following our guide that basically says don't cache anything, use flexible SSL, turn all security off, all performance off, etc.:
Now, lets go through the account settings and make sure we are maximising the performance enhancements for our landers:
- SSL > Overview > set to Flexible as the default
- SSL > Edge Certificates > turn on Always Use HTTPS, Opportunistic Encryption, TLS 1.3 and Automatic HTTPS Rewrites. This way we force HTTPS as much as possible, which is good for tracking/reliability too
- Speed > Optimization > turn on Auto-minify of everything, Brotli, and Rocket Loader
- Caching > Configuration > set the default caching level to Standard
- Network > make sure all toggles here are set to on (leave the pseudo IPv4 off)
Ok, that's all those settings sorted -- you probably didn't have to change much, but I wanted to be thorough.
Now, test it!
Our goal was to use a custom domain and SSL -- so test it!
Load your custom domain, e.g. My Test Page
Hopefully you'll see your HTML page and message and notice that the URL should redirect to HTTPS and show that its secure, since we set up automatic HTTPS rewrites for the domain:
Last edited: