diff --git a/dev/js/src/pageInfo.js b/dev/js/src/pageInfo.js
new file mode 100644
index 0000000..3f8f9a9
--- /dev/null
+++ b/dev/js/src/pageInfo.js
@@ -0,0 +1,21 @@
+"use strict";
+
+define(function () {
+  return {
+    create : function () {
+      const o = Object.create(this);
+      const p = document.getElementById('pagination');
+      o.ds = p ? p.dataset : {};
+      return o;
+    },
+    page : function () {
+      return parseInt(this.ds["page"] || 0);
+    },
+    total : function () {
+      return parseInt(this.ds["total"] || 0);
+    },
+    count : function () {
+      return parseInt(this.ds["count"] || 0);
+    }
+  }
+});
diff --git a/dev/js/src/plugin/server.js b/dev/js/src/plugin/server.js
index 817c0c9..d5295f7 100644
--- a/dev/js/src/plugin/server.js
+++ b/dev/js/src/plugin/server.js
@@ -9,7 +9,7 @@
  */
 "use strict";
 
-define(['plugin/widget', 'plugin/service', 'state', 'util'], function (widgetClass, serviceClass, stateClass) {
+define(['plugin/widget', 'plugin/service', 'state', 'pageInfo', 'util'], function (widgetClass, serviceClass, stateClass, pageInfoClass) {
 
   KorAP.Panel = KorAP.Panel || {};
 
@@ -475,7 +475,7 @@
           };
         }
 
-        // Get Query information from from
+        // Get Query information from form
         else if (d.key == 'QueryForm') {
           let doc = document;
           let v = d["value"] = {};
@@ -502,6 +502,15 @@
           v["q"] = p.get('q');
           v["ql"] = p.get('ql');
           v["cq"] = p.get('cq');
+        }
+
+        // Get pagination information
+        else if (d.key == 'Pagination') {
+          const pi = pageInfoClass.create();
+          let v = d["value"] = {};
+          v["page"] = pi.page();
+          v["total"] = pi.total();
+          v["count"] = pi.count();
         };
 
         // data needs to be mirrored
