Send TradingView Alerts to MT5

mt5-icon

Automating TradingView alerts to MT5 is simple with TradingView To Anywhere. The setup process is very simple and can be completed in under 2 minutes.

To get started, create a Bot on BotFather and submit the bot API key on the website. To avoid errors, copy and paste are recommended. Create a new channel and add two bots:

  1. The bot you created on BotFather. To avoid mistakes and adding the wrong Bots, copy the name of your Bot from Bot father (the one ending with _Bot)
  2. The TradingViewToBot. This bot has the official TradingView To Anywhere logo

Send the /chatid command to your new channel to receive the chat ID (Remember to include the negative sign that comes with it). After submitting your Chat ID, Download the TradingView To MT5 EA and install it to your MT4 (Files>Open Data Folder>MQL4>Experts> paste here).

Go to Tools> Options> Expert Advisors and tick "Allow WebRequest for the listed URL. Add the following two URLs:

  1. https://tradingview.to
  2. https://api.telegram.org

Enable Auto-Trading at the top (should be green) and install the EA on ONE chart only. Input your Webhook and now you are ready to Automate your alerts.

Could I please ask, my situation is that I want to place orders on MT5, and in my case it will be as follows:

I will not have any TP or SL, each order will only have Long/Short and the Ticker and position size.

And the command I’m using on TradingView is as follows: {{strategy.order.action}} {{ticker}} q={{strategy.order.contracts}}

But I find that I am unable to place the desired lot size, and instead I keep encountering “Invalid params” and it just places 0.01 lots. Could you please advise how I can resolve this?

Hello @Wilson96

Could you please share the output of your command, especially q={{strategy.order.contracts}}. Share this as received in your Telegram channel.

Your command may be generating a way too high lot size that is either not allowed by MetaTrader or that is more than your balance.

Tash.