diff --git a/src/HtmlUtils.js b/src/HtmlUtils.js
index 03be6d35a0..dc167ce5c7 100644
--- a/src/HtmlUtils.js
+++ b/src/HtmlUtils.js
@@ -163,6 +163,7 @@ var sanitizeHtmlParams = {
/#[0-9a-fA-F]{6}/.test(customAttributeValue)
) {
style += cssAttributeKey + ":" + customAttributeValue + ";";
+ delete attribs[customAttributeKey];
}
});