diff --git a/widgetsnbextension/src/extension.js b/widgetsnbextension/src/extension.js
index <HASH>..<HASH> 100644
--- a/widgetsnbextension/src/extension.js
+++ b/widgetsnbextension/src/extension.js
@@ -102,9 +102,9 @@ function register_events(Jupyter, events, outputarea) {
      */
     function render(output, data, node) {
         // data is a model id
-        var manager = Jupyter.notebook.kernel.widget_manager;
-        if (!manager) {
-            node.textContent = "Missing widget manager";
+        var manager = Jupyter.notebook && Jupyter.notebook.kernel && Jupyter.notebook.kernel.widget_manager;
+        if (manager === undefined) {
+            node.textContent = "Error rendering Jupyter widget: missing widget manager";
             return;
         }
 
@@ -120,7 +120,7 @@ function register_events(Jupyter, events, outputarea) {
                 PhosphorWidget.Widget.attach(view.pWidget, node);
             });
         } else {
-            node.textContent = "Widget not found: "+JSON.stringify(data);
+            node.textContent = "Error rendering Jupyter widget. Widget not found: "+JSON.stringify(data);
         }
     }
Add a bit more error checking when rendering widgets in the classic notebook.

Works around #<I>