diff --git a/chosen.js b/chosen.js
index bc3b11a..814e456 100644
--- a/chosen.js
+++ b/chosen.js
@@ -25,6 +25,13 @@
           width : ($(this).width() < minWidth) ? minWidth : $(this).width()
         }).chosen(options);
       });
+
+      // Add error class if available.
+      $('.chzn-container').each(function() {
+        if ($(this).prev().hasClass('error')) {
+          $(this).children().addClass('error');
+        }
+      });
     }
   }
 })(jQuery);
