Skip to main content

Last updated: March 13, 2026

How to Screenshot a Specific Element on Any Webpage

Need to capture just a button, card, or any other element? Learn the manual DevTools method and discover a faster alternative.

Why Screenshot Specific Elements?

Taking screenshots of specific elements (instead of full pages) is essential for many development tasks. It gives you clean, focused captures without unnecessary background clutter.

Documentation

Capture UI components for design systems, style guides, or technical documentation without manual cropping.

Client Presentations

Show specific features or design changes to clients with pixel-perfect screenshots of exactly what matters.

Bug Reports

Highlight the exact element causing issues for faster debugging and clearer communication with your team.

The Manual Way

6 Steps

Chrome DevTools has a built-in feature to capture element screenshots, but it requires navigating through the DOM tree - which can be tedious and error-prone.

1

Open Chrome DevTools

Press F12 or Cmd+Option+I (Mac) / Ctrl+Shift+I (Windows) to open DevTools.

DevTools DOM panel with element selected
2

Find the Element in the DOM Tree

Use the Elements panel to navigate through the HTML structure. Click the inspect icon (top-left of DevTools) and click on the element on the page, or manually expand nodes to find it.

Pain Point: For deeply nested elements, you might need to expand dozens of parent nodes to find the exact element you want.
3

Right-Click the Element in DevTools

Once you've found the element in the DOM tree, right-click directly on its HTML tag in the Elements panel.

4

Select "Capture node screenshot"

In the context menu, look for "Capture node screenshot" - it's often buried in the menu and easy to miss.

Right-click menu showing Capture node screenshot option
5

Find the File in Downloads

The screenshot is automatically saved to your Downloads folder. Navigate there to find and rename the file as needed.

!

Common Problem: Incorrect Cropping

DevTools captures the element's computed bounding box, which sometimes includes extra whitespace, clips shadows, or captures more than you intended. You might need multiple attempts to get it right.

Example showing cropping issues with DevTools screenshot

With Frontend Hero

3 Steps

Frontend Hero's Element Screenshot tool lets you click directly on any visible element - no DOM tree navigation required.

1

Click the Element Screenshot Icon

Open Frontend Hero and click the Element Screenshot tool icon. The page enters capture mode.

Frontend Hero Element Screenshot mode activated
2

Click Any Element on the Page

Hover over elements to see them highlighted. Click on the element you want to capture - it's that visual and intuitive.

Pro Tip: You're clicking on the visual element itself, not hunting through code. What you see is what you get.
3

Perfect Screenshot Downloads Instantly

Your screenshot is captured with accurate boundaries and downloads immediately. No cropping issues, no extra whitespace.

Perfect element capture result from Frontend Hero

Side-by-Side Comparison

Steps Required

DevTools:6 steps
Frontend Hero:3 steps

Element Selection

DevTools:Navigate DOM tree
Frontend Hero:Click visually

Accuracy

DevTools:Sometimes incorrect
Frontend Hero:Pixel-perfect

Speed

DevTools:30-60 seconds
Frontend Hero:2-3 seconds

The Bottom Line

Use DevTools when...

  • *You need a quick one-off screenshot
  • *You're already working in DevTools
  • *You don't want to install any extensions

Use Frontend Hero when...

  • *You capture element screenshots regularly
  • *Speed and accuracy matter for your workflow
  • *You also need other tools (CSS inspection, color picking, etc.)

Frequently Asked Questions

Can I screenshot any element on a webpage?

Yes, you can screenshot any visible element on a webpage. This includes buttons, cards, navigation bars, images, forms, or any other HTML element. The element just needs to be visible on the page - hidden elements cannot be captured.

What file format does the screenshot save as?

When using Chrome DevTools' 'Capture node screenshot' feature, screenshots are saved as PNG files. Frontend Hero also saves element screenshots as high-quality PNG files, preserving transparency when applicable.

Why does my DevTools screenshot have extra whitespace?

DevTools captures the element's full bounding box, which can include padding, margins, or extra space from CSS properties like overflow. Some elements also have invisible borders or pseudo-elements that expand the capture area. Frontend Hero's Element Screenshot tool handles these edge cases more accurately.

Can I screenshot elements with hover states?

With DevTools, capturing hover states is tricky because moving your mouse to the context menu removes the hover. Frontend Hero's Element Screenshot mode lets you hover over elements to highlight them, and clicking captures exactly what you see - including any hover effects that are visible at that moment.

Does element screenshot capture shadows and effects?

Yes, both methods capture box shadows, text shadows, and CSS effects. However, if a shadow extends beyond the element's bounding box, it may get clipped. Frontend Hero automatically expands the capture area slightly to include common shadow sizes.

Can I screenshot elements inside iframes?

DevTools can screenshot elements inside iframes if you navigate to the iframe's document in the Elements panel. Frontend Hero can also capture iframe content on most websites, though some cross-origin restrictions may apply for security reasons.

What's the maximum element size I can screenshot?

There's no strict limit, but very large elements (like full-page sections) may result in large file sizes. For extremely tall or wide elements, you might experience memory limitations in the browser. Both DevTools and Frontend Hero handle typical element sizes without issues.