diff --git a/lib/reporters/html.js b/lib/reporters/html.js
index 788240e476..e4737345d9 100644
--- a/lib/reporters/html.js
+++ b/lib/reporters/html.js
@@ -183,7 +183,7 @@ function HTML(runner) {
*/
var makeUrl = function makeUrl(s) {
var search = window.location.search;
- return (search ? search + '&' : '?' ) + 'grep=' + encodeURIComponent(s);
+ return window.location.pathname + (search ? search + '&' : '?' ) + 'grep=' + encodeURIComponent(s);
};
/**