diff --git a/panels_mini/panels_mini.module b/panels_mini/panels_mini.module
index a0aa662..4661a50 100644
--- a/panels_mini/panels_mini.module
+++ b/panels_mini/panels_mini.module
@@ -477,5 +477,37 @@ function panels_mini_panels_dashboard_blocks(&$vars) {
     'class' => 'dashboard-mini-panels',
     'section' => 'left',
   );
+}
 
+/**
+ * Implements hook_form_FORM_ID_alter().
+ *
+ * Adds an optional checkbox to to the "required" context forms. This is useful
+ * for mini panels that take a context but do not entirely depend on the context.
+ * For instance, a sidebar may take a node context and display information based
+ * on that conext. However, there may be other panes within the Mini Panel that do
+ * not need the node context. With the optional checkbox, this Mini Panel can be
+ * used in many different places.
+ */
+function panels_mini_form_ctools_edit_context_form_defaults_alter(&$form, &$form_state, $form_id) {
+
+  if (empty($form['optional'])) {
+
+    $form['optional'] = array(
+      '#type' => 'checkbox',
+      '#title' => t('Optional'),
+      // if there's a value for optional, the default value should be true.
+      '#default_value' => !empty($form_state['conf']['optional']),
+      '#description' => t('Check this box if you want this mini panel available even if this context is not.'),
+    );
+
+    $form['#submit'][] = 'panels_mini_form_ctools_edit_context_form_defaults_form_submit';
+  }
+}
+
+/**
+ * Handles the submission of the form element added in panels_mini_form_ctools_edit_context_form_defaults_alter().
+ */
+function panels_mini_form_ctools_edit_context_form_defaults_form_submit($form, &$form_state) {
+  $form_state['conf']['optional'] = !empty($form_state['values']['optional']);
 }
diff --git a/panels_mini/plugins/content_types/panels_mini.inc b/panels_mini/plugins/content_types/panels_mini.inc
index 6bd4d94..a201943 100644
--- a/panels_mini/plugins/content_types/panels_mini.inc
+++ b/panels_mini/plugins/content_types/panels_mini.inc
@@ -68,8 +68,14 @@ function _panels_mini_panels_mini_content_type_content_type($mini) {
     $type['required context'] = array();
     foreach ($mini->requiredcontexts as $context) {
       $info = ctools_get_context($context['name']);
-      // TODO: allow an optional setting
-      $type['required context'][] = new ctools_context_required($context['identifier'], $info['context name']);
+
+      // Check if the required context is actually required.
+      if (!empty($context['optional'])) {
+        $type['required context'][] = new ctools_context_optional($context['identifier'], $info['context name']);
+      }
+      else {
+        $type['required context'][] = new ctools_context_required($context['identifier'], $info['context name']);
+      }
     }
   }
   return $type;
