# Slides for developers

[Canonical article](https://slides.com/docs/developers)

Slides presentations are HTML documents, which gives developers additional ways to customize their content. You can work with syntax-highlighted code, edit slide HTML, assign custom CSS classes, and export your presentation as HTML.

Slides also provides a [Define API](/docs/define-api) for creating prefilled presentations, a [REST API](/docs/api) for working with decks and account data, and an [MCP Server](/docs/mcp) for connecting AI tools.

## Syntax highlighted code

Code blocks support syntax highlighting for common programming languages and include several highlighting themes. You can also emphasize specific lines and step through multiple line-highlight states while presenting.

&lt;img src=&quot;https://static.slid.es/site/developers/slides-language-theme.gif&quot; alt=&quot;Selecting a language and highlighting theme for a code block&quot; width=&quot;1113&quot; height=&quot;791&quot;&gt;

### Line highlights

Add multiple highlight steps to direct your audience&#39;s attention to different lines. An empty step displays the code without highlighting any lines.

&lt;img src=&quot;https://static.slid.es/site/developers/slides-line-highlights.gif&quot; alt=&quot;Adding and presenting multiple line-highlight steps&quot; width=&quot;1113&quot; height=&quot;485&quot;&gt;

Learn more about [syntax-highlighted code](/docs/syntax-highlighted-code).

## Developer mode

Developer mode adds HTML and CSS controls that are not available in the standard editor interface. Enable it from the editor settings in the lower-left corner.

&lt;img src=&quot;https://static.slid.es/site/developers/slides-developer-mode-1b.png&quot; alt=&quot;Developer mode option in the editor settings&quot; width=&quot;2604&quot; height=&quot;1500&quot;&gt;

### Editing HTML

Open the slide options and select **Edit HTML** to edit the current slide&#39;s markup. Some elements, including `&lt;script&gt;` and `&lt;link&gt;`, are not allowed for security reasons.

&lt;img src=&quot;https://static.slid.es/site/developers/slides-developer-mode-2b.png&quot; alt=&quot;HTML editor for the current slide&quot; width=&quot;3414&quot; height=&quot;1142&quot;&gt;

### Element classes

If your plan includes custom CSS, developer mode adds a class name field to focused content blocks. Assign a class when you need to target a specific block from the CSS editor.

This example defines an `upside-down` class:

```css
.upside-down {
  transform: scale(1, -1);
}
```

&lt;img src=&quot;https://static.slid.es/site/developers/slides-developer-mode-3b.png&quot; alt=&quot;Custom class name applied to a content block&quot; width=&quot;2586&quot; height=&quot;1154&quot;&gt;

### Slide classes

You can also assign a class to a complete slide. Use slide classes for broader changes such as adjusting foreground colors or using a different transition.

&lt;img src=&quot;https://static.slid.es/site/developers/slides-developer-mode-4b.png&quot; alt=&quot;Custom class name applied to a slide&quot; width=&quot;2668&quot; height=&quot;1536&quot;&gt;

The slide content and slide background are separate elements. This example targets both using a class named `night-sky`:

```css
/* Target the slide content */
.slides .night-sky svg path {
  fill: yellow;
}

/* Target the slide background */
.backgrounds .night-sky {
  background: linear-gradient(0deg, #141528, #0b1bb2);
}
```

&lt;img src=&quot;https://static.slid.es/site/developers/slides-developer-mode-5b.png&quot; alt=&quot;Custom CSS changing the appearance of a selected slide&quot; width=&quot;3414&quot; height=&quot;1966&quot;&gt;

### Export HTML

The **Export** panel includes an option to download your presentation as HTML for use with reveal.js. The export contains your slide markup and the core styles needed to present it outside Slides.

&lt;img src=&quot;https://static.slid.es/site/developers/slides-developer-mode-6b.png&quot; alt=&quot;Download HTML option in the Export panel&quot; width=&quot;3414&quot; height=&quot;1966&quot;&gt;

Learn more about [exporting to HTML](/docs/export-to-html-lite-pro) and [developer mode](/docs/developer-mode).

## CSS editor

The CSS editor provides a live preview while you customize your presentation. Open the **Style** panel in the editor and select **CSS editor**. Custom CSS requires a Pro plan.

The editor supports plain CSS and LESS features such as nesting. Slides scopes saved styles to the presentation so they do not affect the surrounding page.

You can also [load custom fonts](/docs/custom-fonts-pro) and use classes assigned through developer mode.

### Examples

```css
/* Change the presentation progress bar color */
.progress span {
  background: #ff0000;
}

/* Change the control arrow color */
.controls button {
  color: #ff0000;
}

/* Change the presentation background */
&amp; {
  background: #a83239;
}

/* Change the body text color */
.slides {
  color: #009999;
}

/* Turn text white on slides with a dark background */
.has-dark-background {
  color: #ffffff;
}

/* Increase the size of slide numbers */
.slide-number {
  font-size: 20px;
}

/* Add a blue border to every slide */
.slides section {
  outline: 1px solid blue;
}

/* Add a red border to every vertical stack */
.slides section.stack {
  outline: 1px solid red;
}

/* Load a custom font */
@font-face {
  font-family: &quot;Cabin Sketch&quot;;
  src: url(&quot;https://static.slid.es/fonts/cabinsketch/cabinsketch-regular.woff&quot;) format(&quot;woff&quot;);
}

.slides h1,
.slides h2,
.slides h3 {
  font-family: &quot;Cabin Sketch&quot;;
}
```

The CSS editor is available from the Style panel:

&lt;img src=&quot;https://static.slid.es/site/developers/slides-css-editor-1b.png&quot; alt=&quot;CSS editor option in the Style panel&quot; width=&quot;3414&quot; height=&quot;1290&quot;&gt;

Changes appear alongside a live preview of the presentation:

&lt;img src=&quot;https://static.slid.es/site/developers/slides-css-editor-2b.png&quot; alt=&quot;CSS editor with a live presentation preview&quot; width=&quot;3414&quot; height=&quot;1290&quot;&gt;

Learn more about [custom CSS](/docs/custom-css-pro).
