diff --git a/docs/content/rc.md b/docs/content/rc.md
index a0094cb65..3067c3405 100644
--- a/docs/content/rc.md
+++ b/docs/content/rc.md
@@ -440,6 +440,7 @@ Returns the following values:
 			...
 		]
 }
+```
 
 ### core/memstats: Returns the memory statistics {#core/memstats}
 
@@ -547,6 +548,7 @@ Returns the following values:
 			}
 		]
 }
+```
 
 ### core/version: Shows the current version of rclone and the go runtime. {#core/version}
 
diff --git a/fs/accounting/stats_groups.go b/fs/accounting/stats_groups.go
index 880cf4500..417f29511 100644
--- a/fs/accounting/stats_groups.go
+++ b/fs/accounting/stats_groups.go
@@ -156,6 +156,7 @@ Returns the following values:
 			}
 		]
 }
+` + "```" + `
 `,
 	})
 
@@ -176,6 +177,7 @@ Returns the following values:
 			...
 		]
 }
+` + "```" + `
 `,
 	})
 
@@ -189,6 +191,7 @@ is provided.
 
 Parameters
 - group - name of the stats group (string)
+` + "```" + `
 `,
 	})
 }