---
title: "Add an image node to your Editor"
description: "Add an image node UI component to your Tiptap Editor. Learn more in our documentation!"
---

> This page is for Tiptap 2.x. [See the latest version of this page.](https://tiptap.dev/docs/ui-components/node-components/image-node.md)

# Add an image node to your Editor

Add an image node UI component to your Tiptap Editor. Learn more in our documentation!

> **Upgrade to v3**
>
> To use UI components or templates you need to upgrade to Editor version 3.x. See the [upgrade
> guide](https://tiptap.dev/docs/resources/whats-new) for more details.

Styling for image nodes in the Tiptap editor.

> **Interactive demo:** [image node](https://template.tiptap.dev/preview/tiptap-node/image-node)

## Install

You can add the node component via Tiptap CLI (for Vite or Next.js)

```bash
npx @tiptap/cli add image-node
```

### Manual Integration

For frameworks other than Vite or Next.js, add the node component manually from the [open-source repository](https://github.com/ueberdosis/tiptap-ui-components/tree/main/apps/web/src/components/tiptap-node/image-node).

### Import styles

This component requires you to import our styles which were added to `styles/keyframe-animation.scss` and `styles/_variables.scss`.

## Usage

The ImageNode provides styling for images within the editor. To use it, include it in your project and ensure you're using the Image extension from Tiptap.

```tsx
import { useEditor, EditorContent } from '@tiptap/react'
import { Image } from '@tiptap/extension-image'
import { StarterKit } from '@tiptap/starter-kit'

import '@/components/tiptap-node/image-node/image-node.scss'

export default function EditorWithImages() {
  const editor = useEditor({
    immediatelyRender: false,
    extensions: [StarterKit, Image],
    content: '<img src="/images/placeholder-image.png" alt="Example image" />',
  })

  return <EditorContent editor={editor} />
}
```

## Features

- Proper image sizing (max-width: 100%)
- Consistent margins and spacing
- Highlighted selection state for better UX
- Border radius for aesthetic appearance
- Compatible with the thread system

## Requirements

Open source feature(s)

- [`@tiptap/extension-image`](https://tiptap.dev/docs/v2/editor/extensions/nodes/image.md) (recommended for full functionality)
