 <p>If I understand you correctly URL rewriting is not what you need. Why? Because mapping an external URL to some internal URL / alias is not going to help you serve the file.</p> <p>What you need is a way to have an external URL process a request and return the file in question. Luckily Drupal 7 makes this pretty easy to do.</p> <p>1.) Define a menu mapping in hook_menu()</p> <pre><code> function MODULE_menu() { $items = array(); $items['pdf'] = array( 'title' => 'Map PDF', 'page callback' => 'MODULE_show_pdf', 'access callback' => TRUE, 'description' => 'TBD', 'type' => MENU_CALLBACK, ); return ($items); } </code></pre> <p>2.) Define your callback function</p> <pre><code> function MODULE_show_pdf($somehtmlfile = '') { $stream_wrapper_uri = 'public://pdf/' . $somehtmlfile . '.pdf'; $stream_wrapper = file_create_url($stream_wrapper_uri); $stream_headers = array( 'Content-Type' => file_get_mimetype($stream_wrapper_uri), 'Content-Length' => filesize($stream_wrapper_uri), 'Pragma' => 'no-cache', 'Cache-Control' => 'must-revalidate, post-check=0, pre-check=0', 'Expires' => '0', 'Accept-Ranges' => 'bytes' ); file_transfer($stream_wrapper_uri, $stream_headers); } </code></pre> <p>Some things to note:</p> <ol> <li><p>There is no need to explicitly define somehtmlfile param in the menu. This allows you more flexibility in that you can simply define whatever params you would like this external URL to support simply by adjusting the params in the callback function.</p></li> <li><p>When public stream wrapper dirs/files are sub-dir of: sites/default/files</p></li> <li><p>It is assumed that although you have somehtmlfile in the URL that you really want to stream somehtmlfile.pdf (if you want to stream somehtmlfile.html then simply adjust the hard coded '.pdf' suffix)</p></li> <li><p>file_transfer calls drupal_exit() as its last step which essentially ends request processing.</p></li> <li><p>Make sure to flush your cache otherwise the above will not work as menu entries are cached and the external URL will fail to be found</p></li> </ol>