#+startup: inlineimages # ()convertfrompdf:t # This is a special comment; tells that the upcoming # link points to a to-be-converted-to file. # If you have a foo.pdf that you need to convert to foo.png, mention the # to-be-converted-to name in the file link. [[./org-mode-unicorn-logo.png]] 1. Save =org-include-img-from-pdf.el= to your =~/.emacs.d/elisp/org-include-img-from-pdf=. 2. Add below to your emacs setup and evaluate it. #+begin_src emacs-lisp (use-package org-include-img-from-pdf :load-path "elisp/org-include-img-from-pdf" :config (progn (with-eval-after-load 'ox (add-hook 'org-export-before-processing-hook #'modi/org-include-img-from-pdf)))) #+end_src 3. Have =org-mode-unicorn-logo.pdf= file in the same directory as this one. 4. Do =C-c C-e h o=. 5. You will find the =.png= image converted from the =.pdf= file and used in the exported HTML file.