On‑Screen Pixel Ruler - Online Measure Elements in Browser
Drag a virtual ruler across your screen to measure pixel distances. Horizontal and vertical guides. Useful for UI designers checking alignment.
UD5 Toolkit
| Category | Width Range | Typical Devices | Status |
|---|---|---|---|
| Small Phone | < 576px | iPhone SE, older Androids | — |
| Large Phone | 576 – 767px | iPhone 14/15, Galaxy S23 | — |
| Tablet | 768 – 991px | iPad Mini, Galaxy Tab | — |
| Small Desktop | 992 – 1199px | Small laptops, older monitors | — |
| Desktop | 1200 – 1399px | Standard monitors, MacBook Pro | — |
| Large Desktop | ≥ 1400px | Wide monitors, 1440p+, 4K | — |
| Device | Resolution | DPR | CSS Viewport | Aspect Ratio |
|---|---|---|---|---|
| iPhone 15 Pro Max | 2790 × 1290 | 3× | 430 × 932 | ~19.5:9 |
| iPhone 15 / 15 Pro | 2556 × 1179 | 3× | 393 × 852 | ~19.5:9 |
| iPhone SE (2022) | 1334 × 750 | 2× | 375 × 667 | 16:9 |
| Samsung Galaxy S24 Ultra | 3120 × 1440 | 3× | 412 × 915 | ~19.5:9 |
| iPad Pro 12.9" | 2732 × 2048 | 2× | 1024 × 1366 | 4:3 |
| iPad Air | 2360 × 1640 | 2× | 820 × 1180 | ~4.3:3 |
| MacBook Pro 14" | 3024 × 1964 | 2× | 1512 × 982 | ~16:10 |
| MacBook Air 13" | 2560 × 1664 | 2× | 1280 × 832 | ~16:10 |
| Full HD Monitor | 1920 × 1080 | 1× | 1920 × 1080 | 16:9 |
| 4K UHD Monitor | 3840 × 2160 | 1× (100% scale) | 3840 × 2160 | 16:9 |
window.innerWidth and window.innerHeight in pixels. This is the actual space available for displaying web content, excluding browser chrome (toolbars, bookmarks bar, etc.). It's crucial for responsive web design because it determines how your layout should adapt.
screen.width × screen.height) is the total number of physical pixels on your display. Viewport size is the browser's content area, which is almost always smaller due to browser UI elements, taskbars, and the fact that browser windows are rarely maximized. For example, a 1920×1080 screen may have a viewport of only ~1440×780 when the browser is not fullscreen.
window.devicePixelRatio. This is critical for serving appropriately sized images (using srcset) and for canvas rendering.
window.innerWidth returns the CSS pixel width of the browser's content area (the viewport), including scrollbars. screen.width returns the total physical pixel width of the entire screen. On a 1920×1080 monitor, screen.width is 1920, but window.innerWidth might be around 1440-1900 depending on browser window size. On Retina displays, screen.width reports CSS pixels (not physical), so a 3024-pixel-wide MacBook screen reports 1512.
srcset with 2x and 3x descriptors for responsive images. For canvas, multiply dimensions by DPR for sharp rendering. For icons, use SVG or icon fonts which scale perfectly at any DPR. CSS media queries like @media (-webkit-min-device-pixel-ratio: 2) can target high-DPI screens specifically.
aspect-ratio property helps maintain proportions. Common ratios: 16:9 (most screens), 16:10 (MacBooks), 4:3 (iPads), 21:9 (ultrawide), 19.5:9 (modern phones).
Drag a virtual ruler across your screen to measure pixel distances. Horizontal and vertical guides. Useful for UI designers checking alignment.
An on‑screen ruler that measures in pixels, centimeters, and inches. Drag to resize. Handy for UI designers and developers.
Display your screen's current devicePixelRatio. See how it changes when you zoom. Useful for high‑res image decisions.
See the current viewport width/height, document size, scrollbar width, and pixel ratio. Essential responsive data.
Predict the file size of an image based on pixel dimensions and format (JPEG, PNG, WebP). Rough estimate. Local.
Resize and crop an image to a specific aspect ratio (1:1, 16:9…) with automatic fit/cover. Download the perfect image.
Enter width, height, format to approximate file size. Plan web performance. Simple model.
Upload two images and see a diff overlay highlighting the pixel differences. Adjust tolerance. For regression testing.
Enlarge pixel art or low‑res images without blur. Choose 2x, 4x, 8x. Perfect for sprites. Download scaled PNG.
Paste media queries and see a visual indicator of which rules apply at current viewport size.
Enter foreground and background colors to instantly see the contrast ratio and pass/fail for AA and AAA. Simple and fast.
Enlarge pixel art or low‑res images without blur. Choose 2x, 4x, 8x. Perfect for sprites. Download scaled PNG.
Create a responsive box that maintains a specific aspect ratio using the aspect‑ratio property. Copy the simple CSS.
Combine aspect‑ratio with min‑/max‑width/height and see how the box responds. Understand sizing constraints. Copy the pattern.
Resize a video by cropping to a new aspect ratio or scaling up/down. Apply and download the result. Browser‑based.
Input dimensions and color depth to estimate uncompressed file size for BMP, PNG, JPEG. Planning tool.
Drop a video file and instantly see its container format, codec(s), resolution, duration, and bitrate. Browser‑based, no upload.
See how your title and meta description will be truncated in Google SERP by pixel width. Optimize click‑through.
Convert pixel values to viewport‑relative units (vw, vh, vmin, vmax) based on a selected breakpoint. Precise responsive design.
Resize an image to exact dimensions and add colored padding to fill the aspect ratio without cropping. Useful for profile grids.
Upload an image and see a slider comparison of different JPEG quality levels. Find the optimal file size vs. quality trade‑off.
Write a media query and see if it matches as you resize the iframe. Understand width, height, and resolution queries.
Enter a website URL and apply a protanopia/deuteranopia/tritanopia filter. Test full page accessibility.
Upload one image at multiple widths and generate the complete img srcset and sizes attributes. Perfect for performance.
Resize images directly in your browser by width, height, or percentage. Maintain aspect ratio and download the result. Images never leave your computer.
Run edge detection algorithms (Sobel, basic Canny) on images directly in the browser. Great for learning computer vision concepts.
Increase or decrease the color saturation of your photo with a slider. Preview instantly. Download the edited image. Canvas‑based.
Point your camera at an object and see the dominant color in real time. Click to copy the hex. Fun tool for designers.
Select visual symptoms (spots, fin rot, swelling) to narrow down possible freshwater fish diseases.
Browse the OKLCH color space with sliders for lightness, chroma, and hue. See the CSS oklch() code. Modern and accessible.