Skip to content
pineconnector rsi strategy pine script

The famous RSI Strategy is modified to be compatible with PineConnector. This strategy/indicator is best used during consolidation or sideways phases in the markets. The strategy can be used for forex trading, stock trading, futures trading, crypto trading and trading of other instruments.

Nevertheless, we recommend that paper trading should be done first, before running on your live trading accounts. 

With this script, an alert will be automatically trigger and will execute a trade on your MT4/5 terminal when your terminal is connected to our server – ideal if you are day trading or swing trading.

Looking to automate your TradingView strategies while your broker is on MetaTrader?
Try PineConnector for 7 days – credit card not required.

Steps to use this RSI Strategy:
Create a PineScript and attach the code below

indicator("PineConnector x RSI Strategy", overlay=true)

length = input( 14 )
overSold = input( 30 )
overBought = input( 70 )
price = close
vrsi = ta.rsi(price, length)
crossover = ta.crossover(vrsi, overSold)
crossunder = ta.crossunder(vrsi, overBought)

long = crossover and not na(vrsi)
short = crossunder and not na(vrsi)

plotshape(long, style=shape.labelup, location=location.belowbar,, 0), size=size.large, text='PineConnector \n Buy',, 0))      //plotting up arrow when buy/long conditions met 
plotshape(short, style=shape.labeldown, location=location.abovebar,, 0), size=size.large, text='PineConnector \n Sell',, 0))  //plotting down arrow when sell/short conditions met

if long
    alert('changetoyourLICENSEID,buy,' +syminfo.ticker+ ',risk=1,sl=20,tp=40', alert.freq_once_per_bar_close)

if short
    alert('changetoyourLICENSEID,sell,' +syminfo.ticker+ ',risk=1,sl=20,tp=40', alert.freq_once_per_bar_close)
Edit the highlighted portion of the code to your preassigned ID found in the PineConnector members area
(e.g. 60123456789)
Save the code, and click "Add to Chart"

Guide to create alerts: Create alerts

● After changing values from 3, please delete the old alert(s) if any and create a new alert
● Please ensure you select PineConnector x RSI strategy when creating an alert, and select alert() function calls only

rsi strategy pineconnector

Recommended PineConnector EA settings:
Volume Type: Percentage of account balance
● Assuming risk=1 and $1000 account,
the EA will compute the position size whereby when the trade hits SL, you will lose 1% or $10.
Target Type: Pips
● Sending in SL=20, and TP=40 will have the EA automatically place SL 20 pips and TP 40 pips away from the entry

1 comment

Hello,I need help to set up autotrade configuration for mt5.Thanks


Leave a comment

Back To PineConnector Script Library