5 votes

Visit Counter

Page Visit Counter

Umbraco 7.3.1+

Is a statistics counter for individual pages

Has a simple label property editor that shows how many times the page has been visited.

It creates a macro, macro partial view, and a data type.

Add the data type to your document type, add the macro to the template, and start counting

Feedback is appreciated

This package saves the node everytime it is visited, to increase the counter, so, per Sebastiaan Janssen's suggestion:

 "please only use this package on very low traffic websites which you don't expect to grow above a few dozen visits a day"

Currently it has english and portuguese localizations


Follow these instructions:

  1. Install the Package (Developer > Packages)
  2. Add the DataType to your DocumentType
  3. Add the Macro to the template page
  4. Every time the page is visited, the counter adds up
Notice that this plugin was developed to simply count the visits, not publish them. In case you need to actually publish the count so you can display it somewhere in your site, please change the macro accordingly (see below):

Macro: (you can paste it over the current code)

@inherits Umbraco.Web.Macros.PartialViewMacroPage
var id = CurrentPage.Id;
var service = ApplicationContext.Current.Services.ContentService;
var content = service.GetById(id);



To display the code, use the following logic (example)

@inherits Umbraco.Web.Mvc.UmbracoTemplatePage
    Layout = null;
int visits = int.Parse(Umbraco.Field("visitCounter").ToString());
<h1>This is the home</h1>
<strong>Visited: @visits</strong>

To start counting, add the macro to the page you intent do track, (and the property in the document type)

This is a simple macro, if you have massive traffic, publishing constantly may have side effects. The plan is making a new visit counter that does not publish it to the page, which will be available soon.


Package owner

Carlos Casalicchio

Carlos Casalicchio

Carlos has 561 karma points

Package Compatibility

This package is compatible with the following versions as reported by community members who have downloaded this package:
Untested or doesn't work on Umbraco Cloud
Version 10.0.x (untested)
Version 9.5.x (untested)
Version 9.4.x (untested)
Version 9.3.x (untested)
Version 9.2.x (untested)
Version 9.1.x (untested)
Version 9.0.x (untested)
Version 8.18.x (untested)
Version 8.17.x (untested)
Version 8.16.x (untested)
Version 8.15.x (untested)
Version 8.14.x (untested)
Version 8.13.x (untested)
Version 8.12.x (untested)
Version 8.11.x (untested)
Version 8.10.x (untested)
Version 8.9.x (untested)
Version 8.8.x (untested)
Version 8.7.x (untested)
Version 8.6.x (untested)
Version 8.5.x (untested)
Version 8.4.x (untested)
Version 8.3.x (untested)
Version 8.2.x (untested)
Version 8.1.x (untested)
Version 8.0.x (untested)
Version 7.15.x (untested)
Version 7.14.x (untested)
Version 7.13.x (untested)
Version 7.12.x (untested)
Version 7.11.x (untested)
Version 7.10.x (untested)
Version 7.9.x (untested)
Version 7.8.x (untested)
Version 7.7.x (untested)
Version 7.6.x (untested)
Version 7.5.x (untested)
Version 7.4.x (untested)
Version 7.3.x (untested)
Version 7.2.x (untested)
Version 7.1.x (untested)
Version 7.0.x (untested)

You must login before you can report on package compatibility.

Package Information

  • Package owner: Carlos Casalicchio
  • Created: 28/06/2016
  • Current version 1.1.2
  • License MIT
  • Downloads on Our: 765

External resources