Free · No signup · Privacy-first

Code to Image

Turn code into beautiful screenshots. 40+ themes, gradient backgrounds, window chrome, and instant export.

Open Editor
Untitled-1
Click to open the full editor, or drop a code file
10 lines

Features

Everything you need to create stunning code screenshots, all in one free tool.

🎨

40+ Themes

Dracula, Nord, Tokyo Night, Catppuccin, Rose Pine, and many more curated dark and light themes.

💻

35+ Languages

JavaScript, TypeScript, Python, Rust, Go, Java, C++, Swift, and dozens more with VS Code-quality highlighting.

📸

PNG, SVG, JPEG

Export in multiple formats. Up to 6x resolution for crystal-clear images on any screen.

🪟

Window Chrome

macOS traffic lights, outline, gray, or Windows buttons. Editable filename with language detection.

🌈

Gradient Backgrounds

16 gradient presets or build your own. Solid colors, custom opacity, and transparent backgrounds.

📋

Copy to Clipboard

One click to copy the rendered image. Paste directly into Slack, Notion, Twitter, or any app.

🔤

Code Fonts

JetBrains Mono, Fira Code, Geist Mono, Cascadia Code, and more. With ligature support.

⚙️

Precise Controls

Padding, radius, shadows, glass borders, font size, line numbers, tab size, and aspect ratio.

Built for Humans and AI Agents

Everything the editor does is scriptable. Render code images from Claude Code, Cursor, CI pipelines, or any MCP-capable agent — and every share link doubles as an image URL.

MCP Server

Add the hosted MCP server and agents get create_code_image, create_share_link, and list_style_options as native tools.

claude mcp add --transport http codetoimage https://codetoimage.com/mcp

REST API

One request in, PNG or SVG out. No key required. Full schema at /api/openapi.json.

curl -X POST https://codetoimage.com/api/image \
  -d '{"code": "const answer = 42;", "theme": "dracula"}' \
  -H 'Content-Type: application/json' -o code.png

Agent Skill

Teach any agent the whole workflow — rendering, share links, and style options — with one install.

npx skills add https://codetoimage.com

Frequently Asked Questions

Is Code to Image free?
Yes, Code to Image is completely free to use with no sign-up required. All features including export, themes, and copy to clipboard are available at no cost.
What programming languages are supported?
Code to Image supports 35+ programming languages including JavaScript, TypeScript, Python, Java, C++, C#, Go, Rust, Swift, Kotlin, PHP, Ruby, HTML, CSS, SQL, Bash, and many more.
What image formats can I export?
You can export your code screenshots as PNG, SVG, or JPEG. Resolution options include 1x, 2x, 4x, and 6x for high-quality output.
Can I copy the image to my clipboard?
Click "Copy Image" to copy a PNG to your clipboard in browsers that support image copying. If copying is unavailable, download the image instead.
What themes are available?
Code to Image offers 40+ themes including popular options like GitHub Dark, Dracula, Nord, Tokyo Night, Catppuccin, One Dark Pro, Night Owl, Rose Pine, and many more dark and light themes.
Can I customize the window appearance?
Yes, you can choose from macOS-style traffic lights, Windows buttons, or no window chrome at all. You can also customize the title, shadow, border style (including a glass effect), and padding.
Is my code stored on your servers?
No. The web editor renders entirely in your browser — code you paste here never leaves your device. Your latest snippet and settings are kept in this browser's local storage so a reload doesn't lose them. If you use the optional API or MCP server, code is rendered statelessly on the server and never stored.
Can AI agents and scripts use Code to Image?
Yes. There is a free REST API (POST /api/image returns a PNG or SVG), a hosted MCP server at codetoimage.com/mcp for Claude Code, Cursor, and other MCP clients, and an installable agent skill (npx skills add https://codetoimage.com). Share links also double as image URLs.
What are the code file and share link limits?
Code files must be text and no larger than 80 KB. Imported files, restored state, share links, and API requests are limited to 20,000 characters and 500 lines. Imports show a warning when a snippet is shortened. Use a focused excerpt for a more readable screenshot, and keep an original copy of your code.