diff --git a/material/base.html b/material/base.html
index 0092ed244..59d77c89d 100644
--- a/material/base.html
+++ b/material/base.html
@@ -85,6 +85,11 @@
{% for path in config["extra_css"] %}
{% endfor %}
+ {% block analytics %}
+ {% if config.google_analytics %}
+ {% include "partials/integrations/analytics.html" %}
+ {% endif %}
+ {% endblock %}
{% block extrahead %}{% endblock %}
{% if palette.primary or palette.accent %}
@@ -211,10 +216,5 @@
{% endfor %}
{% endblock %}
- {% block analytics %}
- {% if config.google_analytics %}
- {% include "partials/integrations/analytics.html" %}
- {% endif %}
- {% endblock %}