Skip to content

Tradingview Chart MCP

MCP server that captures TradingView chart images via Selenium — supports any ticker/interval with browser pooling for concurrent performance

Install

$npx -y @smithery/cli install @ertugrul59/tradingview-chart-mcp --client claude
Claude Code
claude mcp add tradingview-chart-mcp -- npx -y @smithery/cli install @ertugrul59/tradingview-chart-mcp --client claude
Cursor / Claude Desktop (mcp.json)
{
  "mcpServers": {
    "tradingview-chart-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@smithery/cli",
        "install",
        "@ertugrul59/tradingview-chart-mcp",
        "--client",
        "claude"
      ]
    }
  }
}

Install command taken from the project's README or registry entry. Always review code before running it.

MCP Server - TradingView Chart Image Scraper

🚀 Now with Browser Pooling Optimization for 70-80% Better Concurrent Performance!

This MCP server provides tools to fetch TradingView chart images based on ticker and interval with advanced browser pooling for maximum concurrent performance.

🔥 Performance Optimizations

Browser Pooling Technology

  • Production Version: Uses main_optimized.py with browser pooling for maximum concurrent performance
  • Performance Improvement: 70-80% faster for concurrent requests
  • Concurrent Handling: Supports up to 4 simultaneous requests with pre-initialized browser instances
  • Expected Performance:
    • 1 request: ~6-8s (baseline)
    • 2 concurrent: ~3-4s each (60-70% faster)
    • 3 concurrent: ~2.5-3.5s each (70-80% faster)

Version Comparison

  • main_optimized.py (Production): Browser pooling, concurrent optimization, performance tracking
  • main.py (Legacy): Simple single-browser approach, kept for debugging/fallback

Features

  • 🚀 Optimized Chart Image Tool: Fetches direct chart images with browser pooling for maximum concurrent performance
  • 📊 Performance Statistics: Built-in performance monitoring and statistics
  • 🔄 Browser Pool Management: Pre-initialized browser instances for zero-overhead concurrent requests
  • 🎯 Natural Language Prompts: Easy chart requests with interval mapping
  • ⚙️ Environment Configuration: Fully configurable via environment variables
  • 🔐 TradingView Authentication: Secure session-based authentication
  • 💾 Clipboard Capture: Direct base64 image capture for faster performance

Tools

get_tradingview_chart_image

Description: Fetches the direct image URL for a TradingView chart snapshot with optimized concurrent performance.

Performance: This optimized version achieves 70-80% better performance for concurrent requests using browser pooling technology.

Arguments:

  • ticker (str): The TradingView ticker symbol (e.g., "BYBIT:BTCUSDT.P", "NASDAQ:AAPL"). Required.
  • interval (str): The chart time interval (e.g., '1', '5', '15', '60', '240', 'D', 'W'). Required.

Returns:

  • (str): The direct TradingView snapshot image URL (e.g., data:image/png;base64,... or https://s3.tradingview.com/snapshots/...).

Raises:

  • Error (MCP type): If the scraper encounters an error. Error codes:
    • 400: Input error (invalid ticker/interval format)
    • 503: Scraper error (failure during the scraping process)
    • 500: Unexpected internal server error

get_performance_stats

Description: Get performance statistics for the optimized TradingView MCP server.

Returns:

  • Detailed metrics about request performance, improvement over baseline, and browser pool status

Example Output:

🚀 OPTIMIZED TRADINGVIEW MCP SERVER PERFORMANCE STATS
• Total Requests: 12
• Average Time: 3.30s
• Performance Improvement: 70.8%
• Browsers in Pool: 4
• Max Concurrent: 4

Prompts

  • Get the {interval} chart for {ticker}
    • Maps common timeframe names (e.g., "1 minute", "5 minute", "1 hour", "daily") to TradingView codes
  • Show me the daily TradingView chart for {ticker}
    • Specifically requests the daily ('D') chart
  • Fetch TradingView chart image for {ticker} on the {interval} timeframe
    • Comprehensive prompt with timeframe mapping

Setup

Similar plugs

The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.

Fair-code workflow automation platform with native AI capabilities. Combine visual building with custom code, self-host or cloud, 400+ integrations.

Java 面试 & 后端通用面试指南,覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype…

Explore related