diff --git a/dev/js/spec/stateSpec.js b/dev/js/spec/stateSpec.js
index 996eca4..661f394 100644
--- a/dev/js/spec/stateSpec.js
+++ b/dev/js/spec/stateSpec.js
@@ -231,5 +231,18 @@
 
       expect(sm.toString()).toEqual("\"test\":2");
     });
+
+    it('should load stored states', function () {
+      const el = document.createElement('input');
+      el.setAttribute("value","\"test\":2");
+      const sm = stateManagerClass.create(el);
+      expect(sm).toBeTruthy();
+
+      const s1 = sm.newState('test', [1,2,3], 1);
+
+      expect(s1.get()).toEqual(2);
+      
+      expect(sm.toString()).toEqual("\"test\":2");
+    });
   });
 });
diff --git a/dev/js/src/init.js b/dev/js/src/init.js
index f98a3e6..13904ec 100644
--- a/dev/js/src/init.js
+++ b/dev/js/src/init.js
@@ -586,7 +586,17 @@
             };
 
             const input = form.addE("input");
+            input.setAttribute("type","text");
             input.setAttribute("name","state");
+
+            const url = new URL(window.location.href);
+
+            // Access the query parameters to check for states
+            const state = new URLSearchParams(url.search).get('state');
+            if (state != null && state != "") {
+              input.setAttribute("value", state);
+            };
+            
             KorAP.States = stateManagerClass.create(input);
             
             // Load Plugin Server first
diff --git a/dev/js/src/plugin/server.js b/dev/js/src/plugin/server.js
index b95d830..bdc4873 100644
--- a/dev/js/src/plugin/server.js
+++ b/dev/js/src/plugin/server.js
@@ -14,13 +14,7 @@
   KorAP.Panel = KorAP.Panel || {};
 
   const d = document;
-
-  // State manager undefined
-  const states = KorAP.States ? KorAP.States :
-
-        // Not serialized state manager
-        stateManagerClass.create(document.createElement('input'));
-  
+ 
   // Contains all servicess to address with
   // messages to them
   var services = {};
@@ -75,6 +69,11 @@
       this._q      = d.getElementById("q-field")
       this._cutoff = d.getElementById("q-cutoff-field");
 
+       // State manager undefined
+      this._states =  KorAP.States ? KorAP.States :
+        // Not serialized state manager
+        stateManagerClass.create(document.createElement('input'));
+
       return this;
     },
 
@@ -246,7 +245,7 @@
           //   Accept a "value" list here for toggling, which should
           //   also allow for "rolling" through states via CSS classes
           //   as 'toggle-true', 'toggle-false' etc.
-          let state = states.newState(
+          let state = that._states.newState(
             (onClick["state"] ? onClick["state"] : name),
             [true, false],
             onClick["default"]
@@ -651,7 +650,7 @@
 
     // Return states object
     states : function () {
-      return states;
+      return this._states;
     },
 
     // Destructor, just for testing scenarios
diff --git a/dev/js/src/state/manager.js b/dev/js/src/state/manager.js
index 339503d..136310b 100644
--- a/dev/js/src/state/manager.js
+++ b/dev/js/src/state/manager.js
@@ -33,9 +33,9 @@
 
     // Parse a value and populate states
     _parse : function (value) {
-      if (value === undefined || value === '')
+      if (value == null || value == undefined || value == '')
         return;
-      
+
       this._states = JSON.parse('{' + value + '}');
     },
 
@@ -52,7 +52,7 @@
 
     // Update the query component for states
     _update : function () {
-      this._e.value = this.toString();
+      this._e.setAttribute("value", this.toString());
     },
 
 
@@ -63,6 +63,11 @@
       const t = this;
       let s = stateClass.create(values);
 
+      if (this._states[name] != undefined) {
+        if (values.includes(this._states[name]))
+          s.setIfNotYet(this._states[name]);
+      };
+
       // Set default value
       // TODO: It would be better to make this part
       // of the state and serialize correctly using TOJSON()
