A viewport is the portion of a screen or browser window currently available for displaying content. Its size can change with device dimensions, orientation, window resizing, or a foldable phone switching between folded and unfolded states. Web layouts use viewport dimensions to decide how content is arranged and scaled.
In cyber security, the viewport matters because users must be able to see and interact with warnings, consent prompts, and security controls. Attackers may exploit limited or changing screen space to make deceptive content prominent, obscure important details, or place misleading buttons where users are likely to tap. Defenders should test interfaces across viewport sizes and device states, ensuring that security information remains legible and controls are not hidden or crowded out.


