Currently there doesn't seem to be a way to filter global search for headers.
I've tried searches like `# MyHeader`, but the # desn't seem to match the leading #s, just later #s (like in tags).
You can search for headers using just the header text (like "My Header" to search for "# My Header"), but there doesn't to be a way to filter out the non-headers.
This has been a challenge for a while (maybe since global search was launched), but I just hadn't got around to reporting it until now.
Thanks!