Code Screenshot Generator

Paste code, style it, and export as a PNG image.

Preview

function greet(name: string): string {
  return `Hello, ${name}!`;
}

console.log(greet("World"));

About This Tool

How to Use
  1. Paste your code into the editor
  2. Select the programming language for syntax highlighting
  3. Choose a theme (One Dark, Dracula, One Light, VS)
  4. Adjust padding, background color, and corner rounding
  5. Click Download PNG to export the styled snippet as an image
Common Use Cases
  • Sharing code snippets on Twitter, LinkedIn, or blog posts
  • Creating attractive code examples for documentation or presentations
  • Adding styled code blocks to design mockups
  • Teaching programming concepts with visually appealing examples
Tips & Tricks
  • Dark themes like One Dark and Dracula tend to look best on social media
  • Increase padding for a more spacious, professional look
  • Use a transparent or matching background when embedding in slides

Related Tools