I have files with fragments of boilerplate HTML that will be read and output by PHP. I'd rather not use ".html" extension for these files because I'd like to reserve ".html" to indicate a complete HTML page.
Is there an established filename extension for HTML fragments?
If you are include()-ing it into PHP scripts, you can give it any extension, as PHP won't care. I typically give it a .php suffix so that I can throw a line or two of code at the top to keep it from being called directly via HTTP (if that is a concern).
readfile(), include(), require(), file_get_contents(): it doesn't matter. PHP won't care what the suffix is, so use whatever you like -- including my suggestion for ".php" if you want to prevent direct access via browsers.
"Please give us a simple answer, so that we don't have to think, because if we think, we might find answers that don't fit the way we want the world to be."
~ Terry Pratchett in Nation