diff --git a/docs/build.gradle b/docs/build.gradle
index 1a1e3b10e02..d17057242d1 100644
--- a/docs/build.gradle
+++ b/docs/build.gradle
@@ -144,6 +144,10 @@ doxygen {
exclude '*.pb.h'
+ // Save space by excluding protobuf and eigen
+ exclude 'Eigen/**'
+ exclude 'google/protobuf/**'
+
aliases 'effects=\\par Effects:^^',
'notes=\\par Notes:^^',
'requires=\\par Requires:^^',