Command Palette

Search for a command to run...

UnylyUnyly
Browse all

Viewport Control

FreeNot checked

viewport-control is a TypeScript-based MCP server that enables advanced browser automation for viewport management, screenshot capture, and content extraction.

GitHubEmbed

About

viewport-control is a TypeScript-based MCP server that enables advanced browser automation for viewport management, screenshot capture, and content extraction. It is designed for integration with MCP clients (such as Claude Desktop) and provides a robust API for launching, resizing, and closing Chromium-based browser

README

Advanced viewport management and browser control for Model Context Protocol (MCP) clients

Overview

This TypeScript-based MCP server provides sophisticated browser viewport control capabilities. It enables clients to launch browsers with custom viewport configurations, resize viewports dynamically, and capture screenshots with various formatting options. Built on Puppeteer, it offers precise control over browser dimensions and rendering parameters.

Core Features

1. Browser Launch Control

Launch browser instances with precise viewport configurations:

  • Custom dimensions (320-3840px width, 240-2160px height)
  • Device scale factor (1-3x pixel density)
  • Mobile emulation toggle
  • Screenshot capture options (format/quality)

2. Dynamic Viewport Resizing

Adjust viewport dimensions on active browser sessions:

  • Real-time width/height adjustments
  • Format-preserving screenshot capture
  • Quality-adjustable image output (JPEG/WebP)

3. Comprehensive Browser Management

  • Full lifecycle control (launch/close)
  • OS-specific Chrome path detection
  • Headless browser operation
  • Network idle detection for page loading

Tool Specifications

launch_browser

Parameters:

{
  "url": "https://example.com",
  "width": 1200,
  "height": 800,
  "deviceScaleFactor": 2,
  "isMobile": false,
  "imageFormat": "jpeg",
  "imageQuality": 85,
  "fullPage": true
}

Capabilities:

  • Returns page content as markdown
  • Provides base64-encoded screenshot
  • Auto-detects Chrome installation path

resize_viewport

Parameters:

{
  "width": 800,
  "height": 600,
  "imageFormat": "png"
}

Output:

  • Updated viewport dimensions
  • New page content summary
  • Screenshot in specified format

close_browser

Parameters: None Functionality: Cleanly terminates browser instance

Development Workflow

Setup Commands

# Install dependencies
npm install

# Build production version
npm run build

# Watch for changes during development
npm run watch

# Run with MCP inspector for debugging
npm run inspector

Installation Guide

  1. Clone repository:
git clone https://github.com/yourname/viewport-control.git
  1. Configure MCP client (Claude Desktop):
{
  "viewport-control": {
      "timeout": 60,
      "command": "node",
      "args": [ "C:\\Users\\$USRPROFILE$\\something-folder\\whatever-folder\\viewport-control\\build\\index.js" ],
      "transportType": "stdio"
    } 
}

Platform Notes:

  • Windows: Auto-detects Chrome installation
  • macOS: Requires Chrome at default path
  • Linux: Requires manual Chrome installation

Debugging with MCP Inspector

  1. Start server in debug mode:
npm run inspector
  1. Connect browser to provided URL

  2. Use inspector features:

  • Request/response tracing
  • Resource access monitoring
  • Tool execution visualization
  • Error diagnostics

Contributing

  1. Fork the repository
  2. Create feature branch
  3. Implement changes
  4. Add test cases
  5. Submit pull request

License

MIT License - See LICENSE file for details

from github.com/chipsxp/viewport-control

Installing Viewport Control

This server has no published package — it is built from source. Open the repository and follow its README.

▸ github.com/chipsxp/viewport-control

FAQ

Is Viewport Control MCP free?

Yes, Viewport Control MCP is free — one-click install via Unyly at no cost.

Does Viewport Control need an API key?

No, Viewport Control runs without API keys or environment variables.

Is Viewport Control hosted or self-hosted?

Self-hosted: the server runs locally on your machine via the install command above.

How do I install Viewport Control in Claude Desktop, Claude Code or Cursor?

Open Viewport Control on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.

Related MCPs

Playwright

Browser automation, scraping, screenshots

Microsoftby Microsoft

Puppeteer

Browser automation and web scraping.

modelcontextprotocolby modelcontextprotocol

Garmin Connect

An MCP server for Garmin Connect that provides access to fitness activities, health statistics, and sleep data by routing requests through a headless browser to

etweisbergby etweisberg

Higgsfield Unlimited

MCP server for Higgsfield AI that enables unlimited-mode image, video, audio generation, uploads, and job management via multiple parallel accounts, using brows

nukIeerby nukIeer

opentabs-dev/opentabs

Plugin-based MCP server + Chrome extension that gives AI agents access to web applications through the user's authenticated browser session. 100+ plugins with a

opentabs-devby opentabs-dev

robhunter/agentdeals

1,500+ developer infrastructure deals, free tiers, and startup programs across 54 categories. Search deals, compare vendors, plan stacks, and track pricing chan

robhunterby robhunter

hlydecker/ucsc-genome-mcp

MCP server to interact with the UCSC Genome Browser API, letting you find genomes, chromosomes, and more.

hlydeckerby hlydecker

34892002/bilibili-mcp-js

A MCP server that supports searching for Bilibili content. Provides LangChain integration examples and test scripts.

34892002by 34892002

achiya-automation/safari-mcp

Native Safari browser automation for AI agents with 80+ tools. No Chrome dependency, optimized for Apple Silicon with 60% less CPU overhead.

achiya-automationby achiya-automation

agent-infra/mcp-server-browser

Browser automation capabilities using Puppeteer, both support local and remote browser connection.

bytedanceby bytedance

Compare Viewport Control with

Not sure what to pick?

Find your stack in 60 seconds

Author?

Embed badge for your README

Browse similar

All browse MCPs