DEV Community

Cover image for Article 8: Quantitative Trading - Differences Between tradeUI and webserverUI
itrade icu
itrade icu

Posted on • Originally published at itrade.icu

Article 8: Quantitative Trading - Differences Between tradeUI and webserverUI

πŸ” Article 8: Quantitative Trading - Differences Between tradeUI and webserverUI

Although both are often used together, their roles and startup logic are completely different. Below is a detailed comparison πŸ‘‡

πŸš€ Want to learn quantitative trading?

πŸ‘‰ Click to visit: https://itrade.icu
Here you'll find a wealth of content, including Freqtrade Basic Tutorial, Strategy Source Code, Indicator Analysis, and more, to help you easily master quantitative trading techniques!

Item freqtrade trade freqtrade webserver
βœ… Startup Content Starts the trading bot (live or dry-run) Starts the visualization UI service (for viewing data)
βš™οΈ Core Function Executes strategies, places orders, monitors markets Graphically displays strategy performance/backtest results
🧠 Runs Strategy Logic? βœ… Yes (runs strategy in real-time) ❌ No (only reads and displays data)
πŸ“¦ Data Source Real-time market data, order execution Local SQLite database (or strategy output)
⏱ Use Case Live trading (simulated or real) View strategy performance/order info in browser
πŸ”— Connects to Exchange? βœ… Yes ❌ No
πŸ“ˆ View Backtest Results? ❌ No βœ… Supports backtest visualization
πŸš€ Browser Access Address Optional UI, runs in background http://127.0.0.1:8080 (default)

βœ… Use Case Distinction

1. trade Runs the Bot

You can choose live trading or dry-run (simulated trading):

freqtrade trade \
  --config user_data/config.json \
  --strategy MyStrategy \
  --dry-run
Enter fullscreen mode Exit fullscreen mode
  • Continuously fetches real-time market data
  • Executes strategy logic (e.g., buy/sell signals)
  • Connects to the exchange, records orders, funds, and profits
  • Writes all data to a local database (SQLite)

πŸ’‘ Without this, the bot won't do anything!

2. webserver Provides a Graphical Interface

It only reads data and provides a browser-based interface:

freqtrade webserver \
  --config user_data/config.json \
  --username admin --password 123456
Enter fullscreen mode Exit fullscreen mode
  • Displays current holdings, trade history, and strategy name
  • Allows viewing of live strategy performance
  • Can also display backtest result charts (e.g., after running backtesting)

❗ Does not run strategies or connect to exchanges!


Image


πŸ”„ Relationship Summary

  • trade is the "bot engine"
  • webserver is the "graphical interface"

You can think of it like this:

  • trade is the executor that does the actual work
  • webserver is the observation window

If you only run webserver without running trade, you’ll only see previously recorded data, and no new trades will be generated.


🧩 Practical Advice (Docker Environment)

services:
  trader:
    image: freqtradeorg/freqtrade:stable
    command: >
      trade
      --config /quants/freqtrade/user_data/config.json
      --strategy MyStrategy

  ui:
    image: freqtradeorg/freqtrade:stable
    command: >
      webserver
      --config /quants/freqtrade/user_data/config.json
      --username admin
      --password 123456
    ports:
      - "8080:8080"
Enter fullscreen mode Exit fullscreen mode

Then, open your browser and visit: http://localhost:8080 to access your trading bot's dashboard.

Top comments (0)