Dracula Icon

Markdown CSS

Dracula Theme for Markdown CSS

markdown-css - Theme preview

§Dracula for Markdown CSS

§Install

§Option 1: Download

  1. Save dracula-markdown.css into your project
  2. Reference it from your HTML:
<link rel="stylesheet" href="dracula-markdown.css" />

§Option 2: CDN

<link
  rel="stylesheet"
  href="https://cdn.jsdelivr.net/gh/dracula/markdown-css/dracula-markdown.css"
/>

§Option 3: npm

npm install dracula-markdown-css
import "dracula-markdown-css/dracula-markdown.css";

§Usage

§Basic Usage

The default build targets plain HTML elements, so your compiled markdown should sit in the document (or a subtree) that loads this stylesheet:

<!DOCTYPE html>
<html>
  <head>
    <link rel="stylesheet" href="dracula-markdown.css" />
  </head>
  <body>
    <h1>My Markdown Content</h1>
    <p>
      Headings, paragraphs, and other elements pick up the Dracula palette
      automatically.
    </p>
  </body>
</html>

§With a Container Class

To style only part of a page, load the scoped build and wrap the rendered markdown in .dracula-markdown:

<link rel="stylesheet" href="dracula-markdown-scoped.css" />

<div class="dracula-markdown">
  <!-- Your markdown content here -->
</div>

§Included Files

FileDescription
dracula-markdown.cssElement-level rules (typical headings, paragraphs, lists, code, etc.)
dracula-markdown-scoped.cssSame look, gated behind the .dracula-markdown container

§Color Palette

Colors follow the canonical Dracula specification:

ElementColorHex
BackgroundBackground#282A36
TextForeground#F8F8F2
HeadingsPurple#BD93F9
LinksCyan#8BE9FD
CodeGreen#50FA7B
BoldOrange#FFB86C
ItalicYellow#F1FA8C
BlockquotesComment#6272A4
List markersPink#FF79C6

Mist Over Transylvania

Morbius