Overview

Installing & using nullstack analytics is quite easy, all you need is copy and paste 6 lines of tracking code to webpages which you want to track and you're ready to go!

Following documentation provides hints and suggests methods to automate your tracking code installation process based on your platform. mentioned code samples available at this github repository.
Also you can report bugs and discuss about features on the issues page

Supported Platforms


Webpages Nullstack analytics intended to use with online web pages which delivering content with html markup language. It uses client side javascript to collect visitor information and pushes them to your encrypted database which hosted at nullstack servers. Primary purpose of nullstack analytics is measure real human traffic, track anonymous visitors and watch their behaviour on your website.

Cross platform apps Tracking code also can be installed to web powered mobile & desktop applications which acts an extension of your website. At least one domain name required to install nullstack analytics into a mobile/desktop application.

Native Apps Platform specific native apps (android,ios,windows,osx) officially not supported by nullstack analytics.


Managing domains

Add New

1.You will see domain registration page after the sign up, Navigate "Account > Domains > Add New" if you're adding your next domain

2.Give a friendly name and enter the your site url

click to zoom


3.Copy the provided tracking code and keep it at somewhere safe for your next 5 minutes

click to zoom


4.Open your website's index page and append tracking code before the </body> tag. follow the instructions if you're need help for third party platforms.

click to zoom


5.Visit your website after installation, you will see a confirmation message if code installed correctly.

click to zoom



Remove Domain

Navigate "Account > Domains" and hover over your domain which you want to process. Click "Remove" to de-register domain and delete all related tracking data.

click to zoom



Installation


Once you sign up for a nullstack account, keep your site id (eg. NST-XXX) handy and follow guides below.

Standard Installation

Open your index page (usually index.html or main.html) in your favorite text editor, replace the mentioned text with your site id in following code block and paste it to before </body> tag of your html file.
Repeat same process for all your pages which you want to monitor.

        
			
<script type="text/javascript">
  (function (t, r, a, c, k) {
    window._nsusr = "[YOUR SITE ID]";
    c = a.createElement(r);
    k = a.getElementsByTagName(r)[0];
    c.async = 1;
    c.src = t;
    k.parentNode.insertBefore(c, k);
})('//static.nullstack.co/file/analytics/track.js', 'script', document);
</script>
			
                    
                    
                    click to download image
                    
                    

Content Management Systems

Most content management systems does not allow source code editing directly, Installation method basically same as standard installation but you have use their own tools. you will get a tracking code after sign up for nullstack analytics, copy it and find your cms software below for detailed instructions.


Wordpress

http://wordpress.org

1.Login to your administration page at http://yoursite.com/wp-admin/

2.Navigate to menu "Appearance > Editor" and launch the theme editor

click to zoom


3.Find the footer page from right column (usually footer.php)

click to zoom


4.Find the </body> tag

click to zoom


5.Paste your tracking code before </body> tag

click to zoom


6.Click "update file" to save your modifications

click to zoom


visit your site to send first telemetry, it's successfully installed if you're redirected to analytics dashboard after the sign in.


Ghost

http://ghost.org

1.Login to your administration page at http://yoursite.com/ghost/

2.Navigate to menu "Settings > Code Injection" and launch the editor

click to zoom


3.Find the blog footer area

click to zoom


4.Paste your tracking code

click to zoom


5.Click "save" on right upper corner to publish changes

click to zoom


visit your site to send first telemetry, it's successfully installed if you're redirected to analytics dashboard after the sign in.


Drupal

http://drupal.org

Drupal does not provide any access to internal source code, you have to navigate into your installed theme and patch the analytics code manually. following guide demonstrates how to edit theme in cpanel environment.

1.Start file manager and navigate to web root directory (usually "public_root")

2.Navigate to folder "/core/themes/bartik/templates" replace "bartik" with your active theme

click to zoom


3.Open the file "page.html.twig"

click to zoom


4.Find the </footer> tag and paste your tracking code before it

click to zoom


5.Click "save" on right upper corner to publish changes

click to zoom


visit your site to send first telemetry, it's successfully installed if you're redirected to analytics dashboard after the sign in.


Joomla

http://joomla.org

1.Login to your joomla administration page (usually it's yoursite.com/administrator)

2.Navigate to menu "Extensions > themes > themes"

click to zoom


3.Select your currently installed theme

click to zoom


4.Find and open the index.php from left column

click to zoom


5.Find the </body> tag

click to zoom


6.Paste your tracking code before the </body> tag

click to zoom


7.Click "save" on left upper corner to publish changes

click to zoom


visit your site to send first telemetry, it's successfully installed if you're redirected to analytics dashboard after the sign in.

eCommerce Platforms

tracking code installation to an eCommerce platform basically same as content management systems, you don't have to do anything special to measure customer conversion, nullstack analytics does that automatically.


Shopify

http://shopify.com

1.Login to your shopify dashboard (usually it's yourstore.com/admin)

2.Navigate to menu "Sales Channels > Online Store > Themes"

click to zoom


3.Select "Edit HTML/CSS" from three dot menu

click to zoom


4.Find and open the theme.liquid.php from left column

click to zoom


5.Find the </body> tag

click to zoom


6.Paste your tracking code before the </body> tag

click to zoom


6.Click "save" on right upper corner to publish changes

click to zoom



Magento

http://magento.com

1.Login to your magento admin panel (usually it's yourstore.com/admin or yourstore.com/index.php/admin)

2.Navigate to menu "CMS > Static Blocks"

click to zoom


3.Find and open a static block which appear on every page, we selected "Footer Links Company" on our theme

click to zoom


4.Click "show/hide editor" to toggle html editor

click to zoom


5.Append tracking code into last line

click to zoom


6.Click "Save Block" to publish modifications

click to zoom


6.[Optional] Sometimes magento does not reflect changes immediately, Navigate to cache management page from menu "System > Cache Management" and click "Flush Magento Cache" to reload modified pages

click to zoom


Web Frameworks

Web frameworks usually standalone scripts which has single entrypoints, if scripting language supports the output buffering we can render html page into memory and manipulate the content on the fly before push it back to client. You can find code samples which adapted for few popular php frameworks, basically you can apply same logic to all frameworks if you know the entrypoint of the web application.


Laravel [PHP]

http://laravel.com

Laravel's entry point is /public/index.php you can safely replace the file with following code to install nullstack analytics.
Don't forget to replace site id with your one.

        
			
<?php
$track = '<script type="text/javascript">
            (function (t, r, a, c, k) {
            window._nsusr = "NST-Qca2dc";       // replace site id with your one
            c = a.createElement(r);
            k = a.getElementsByTagName(r)[0];
            c.async = 1;
            c.src = t;
            k.parentNode.insertBefore(c, k);
            })(\'//static.nullstack.co/file/analytics/track.js\', \'script\', document);
        </script>';


// skip code injection on ajax requests
$isAjax = (isset($_SERVER['HTTP_X_REQUESTED_WITH']) && ( $_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest' ));

if($isAjax) {
ob_start(function($buffer) {
    global $track;
    return str_ireplace("</body>", $track . "</body>", $buffer);
});
}

require __DIR__.'/../bootstrap/autoload.php';
$app = require_once __DIR__.'/../bootstrap/app.php';
$kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);

$response = $kernel->handle(
    $request = Illuminate\Http\Request::capture()
);

$response->send();
if($isAjax) {
ob_end_flush();
}
$kernel->terminate($request, $response);

			
                    

CodeIgniter [PHP]

http://codeigniter.com

CodeIgniter's entry point is /index.php but it's content more than 100 lines, you have to find following block (usually the last line of index.php)

        
			
..
require_once BASEPATH . 'core/CodeIgniter.php';
..
			
                    

and replace it with:

        
			
$track = '<script type="text/javascript">
  (function (t, r, a, c, k) {
    window._nsusr = "NST-Qca2dc";
    c = a.createElement(r);
    k = a.getElementsByTagName(r)[0];
    c.async = 1;
    c.src = t;
    k.parentNode.insertBefore(c, k);
  })(\'//static.nullstack.co/file/analytics/track.js\', \'script\', document);
</script>';

if (isset($_SERVER['HTTP_X_REQUESTED_WITH']) && ( $_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest' )) {
// skip code injection on ajax requests to save cpu
require_once BASEPATH . 'core/CodeIgniter.php';
} else {
ob_start(function($buffer) {
    global $track;
    return str_ireplace("</body>", $track . "</body>", $buffer);
});
require_once BASEPATH . 'core/CodeIgniter.php';
ob_end_flush();
}
			
                    

Frequently Asked Questions

Following questions are very common feedbacks at the support desk and social channels, you can contact us if you can't find your answer below.

How many sites can i add?

Free package allows to add one domain with unlimited features, you can check out the pricing page if you need to add more than one domain.

Is it possible to interact with visitors?

Unfortunately, no. nullstack analytics is a read-only service and only collects information from your visitors. it's completely invisible on your webpage and does not show any extra content.

I can't see some visitor's spent time

Nullstack analytics uses html5 beacon api to measure spent time of visitors, it's supported in all modern browsers and still people exists in the world who uses IE 6.0 or similar. there is nothing we can do but you can programmatically determine browser version and suggest a browser upgrade to your visitors.

Can i use it with other services?

Absolutely yes. tracking code of nullstack analytics leaves low footprint and does not interfere with any libraries. it's safe to use but using multiple analytics software same time might reduce your page load performance.

Can i access to my raw data?

It's available to only enterprises, by subscribing an enterprise package you will get extra options on your dashboard and you can export your site data in csv, xls or sql format.

Is it possible to quit without any trace?

Privacy is the key point of nullstack analytics, navigate to "account" menu and click "Deactivate Account" your membership will be deactivated and your data will be queued for deletion for next 24 hours.

What's the difference from others?

All analytics services provides different unique options for generic usage, for example you have personal blog and they're tell you how much earned from your store with a lot of zeroes. and you have to see this on each page visit. and most of them doesn't give any detail about spesific detail about visitors. Nullstack analytics provides detail about exactly who visited your website and helps you to disquintish them from bots and real humans

I got high traffic, Is there any limit?

Nullstack analytics capped to 1k unique visitors per hour due to security purposes, after that it's only increments the visitor count.

I changed my mind, can i get a refund?

Refunds are only applicable if you cancel subscription in next 24 hours.

What happens to my domains if i downgrade membership?

Nullstack analytics still processes their visitor data, but you can only see the first domain which you registered. you can use them by re-subscribing to a package or delete them by sending us a request.