diff --git a/site/src/routes/docs/_sections.js b/site/src/routes/docs/_sections.js
index bb081a050b..3657ba85ac 100644
--- a/site/src/routes/docs/_sections.js
+++ b/site/src/routes/docs/_sections.js
@@ -85,7 +85,7 @@ export default function() {
renderer.heading = (text, level, rawtext) => {
let slug;
- const match = /(.+)<\/a>/.exec(text);
+ const match = /]*>(.+)<\/a>/.exec(text);
if (match) {
slug = match[1];
text = match[2];