--- id: mss version: "10.2.0" license: MIT License Copyright (c) 2013-2026, Mickaël 'Tiger-222' Schoentgen Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files… (full text in the JSON record) license_treatment: permissive maintenance: active --- # mss — An ultra fast cross-platform multiple screenshots module in pure python using ctypes. License: permissive · Maintenance: active · Downloads: 3.2M/mo ## What it is and what it does MSS is a pure-Python screenshot capture library that grabs images from one or multiple monitors and saves them as PNG files or returns pixel data for programmatic use. It uses ctypes to call platform-native APIs (BitBlt on Windows, CGGetActiveDisplayList on macOS, XGetImage on Linux) without requiring compiled dependencies, making it lightweight and fast across operating systems. The library is designed for scenarios where speed and simplicity matter: embedding screenshot functionality into games, computer vision pipelines, AI applications, or automation tools. It integrates cleanly with PIL for format conversion and with NumPy and OpenCV for image processing, and it's thread-safe for concurrent use. Use it for: - Capture screenshots in automated testing or monitoring scripts that need to verify UI state or record visual logs - Grab display frames for computer vision or AI model input without external dependencies - Build screen recording or streaming applications that need fast, cross-platform pixel access - Embed screenshot functionality in games or interactive software requiring platform-optimized capture - Monitor multiple displays in a single operation for multi-screen environments or headless setups ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Captures screenshots from one or all monitors on Windows, macOS, and Linux, saving them as PNG files or returning raw pixel data for further processing. Yes. MSS is production-stable, actively maintained, has zero security vulnerabilities, no runtime dependencies, and installs with minimal friction. It's the right choice if you need fast, simple cross-platform screenshot capture without heavyweight dependencies. Only skip it if you need advanced image manipulation (use PIL/Pillow alongside it) or if your use case requires features beyond basic capture. ## Install pip install mss uv add mss poetry add mss ## Installing mss Before you install: Low friction: pure Python with no runtime dependencies, distributed as a wheel, and actively maintained with recent releases. Supports Python 3.9+ across CPython and PyPy. License in practice: MIT License permits unrestricted use, modification, and distribution in both open-source and proprietary projects, with only attribution and license inclusion required. Quickstart: pip install mss from mss import MSS with MSS() as sct: sct.shot() Requires Python 3.9 or later. On systems with external monitors and DPI scaling, import mss before other packages like mouseinfo or pyautogui to avoid conflicts with SetProcessDpiAware(). Verify before relying: - Performance characteristics compared to other screenshot libraries on specific hardware configurations - Behavior with multi-GPU setups or virtual displays - Interaction with DPI-aware applications beyond the documented mouseinfo/pyautogui caveat ## Package facts - License: MIT License Copyright (c) 2013-2026, Mickaël 'Tiger-222' Schoentgen Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files… (full text in the JSON record) (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 3.2M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags screenshot capture python, multi-monitor screen grab, cross-platform screenshot tool, screen capture ctypes, grab display pixels python, screen-capture, cross-platform, computer-vision [View on SkillFed](https://skillfed.io/packages/mss) · [View on PyPI](https://pypi.org/project/mss/)