Native resolution 1080 × 2400 px at 2.75× · 414 PPI · 6.36″ · 9:20. Design at 393 × 873 and export assets at 2.75×.
| Property | Value |
|---|---|
| CSS viewport (portrait) | 393 × 873 px |
| CSS viewport (landscape) | 873 × 393 px |
| Native resolution | 1080 × 2400 px |
| Device pixel ratio | 2.75× |
| Pixel density | 414 PPI |
| Screen diagonal | 6.36 in |
| Panel size | 2.61 × 5.8 in |
| Aspect ratio | 9:20 |
| Total pixels | 2.59 MP |
| Released | 2023 |
| Operating system | Android |
Among the 130 phones on this site, the Xiaomi 13 has the 57th largest CSS viewport area. Its 393 px width is 6 px below the 399 px average for this category.
Targeting the Xiaomi 13 in CSS
Device-specific media queries are brittle — a new model with the same width will not match. Use them for genuine per-device fixes only, and prefer width buckets for layout.
/* Target Xiaomi 13 specifically */
@media only screen
and (device-width: 393px)
and (device-height: 873px)
and (-webkit-device-pixel-ratio: 2.75) {
/* … */
}
/* More useful in practice — the width bucket it falls into */
@media (min-width: 393px) { /* … */ }
Compare with other Android Phones models
| Device | CSS viewport | Native | DPR | PPI | Diagonal |
|---|---|---|---|---|---|
| Xiaomi 13 | 393 × 873 | 1080 × 2400 | 2.75× | 414 | 6.36″ |
| Samsung Galaxy S23 FE | 360 × 780 | 1080 × 2340 | 3× | 403 | 6.4″ |
| Samsung Galaxy A54 | 360 × 780 | 1080 × 2340 | 3× | 403 | 6.4″ |
| Samsung Galaxy A15 | 360 × 780 | 1080 × 2340 | 3× | 396 | 6.5″ |
| Google Pixel 8 | 412 × 915 | 1080 × 2400 | 2.625× | 428 | 6.2″ |
| Samsung Galaxy S23+ | 384 × 833 | 1080 × 2340 | 2.81× | 390 | 6.6″ |
| Samsung Galaxy A34 | 360 × 780 | 1080 × 2340 | 3× | 390 | 6.6″ |
| Samsung Galaxy A14 | 360 × 803 | 1080 × 2408 | 3× | 400 | 6.6″ |
| Samsung Galaxy S23 | 360 × 780 | 1080 × 2340 | 3× | 425 | 6.1″ |
Questions about the Xiaomi 13 screen
What is the screen size of the Xiaomi 13?
The Xiaomi 13 has a 6.36-inch display. In CSS the viewport measures 393 × 873 px in portrait, and the panel itself has 1080 × 2400 physical pixels at 414 PPI.
What resolution should I design for on the Xiaomi 13?
Design at 393 × 873 and export assets at 2.75×. That gives you 1080 × 2400 px images, which is exactly what the panel renders. Designing directly at 1080 × 2400 means every measurement is 2.75 times larger than the CSS values you will write.
What is the device pixel ratio of the Xiaomi 13?
The Xiaomi 13 reports a device pixel ratio of 2.75. One CSS pixel therefore covers 7.56 device pixels. You can read it in JavaScript with window.devicePixelRatio.
Which other devices have the same viewport as the Xiaomi 13?
2 other devices share the 393 × 873 CSS viewport: Xiaomi Redmi Note 13, Xiaomi Redmi Note 12. A layout that works on one works on all of them.
Related
window.innerWidth/innerHeight reported by the stock browser with no browser chrome. See methodology and sources.